Ask Your Question

I don't find my Sage files?

asked 2012-07-23 14:31:24 +0100

sezar543 gravatar image

Hi, I wrote a program which does some computations on SAGE 5.0. I used Virtualbox Manager and my laptop has windows 7. Some days ago, my laptop fell and its hard disk broke. Furtunately, I am able to recover my files (by an external cable connecting the hard disk to a PC). But I couldn't find my program in SAGE. I bought a new hard disk and installed SAGE 5.0 on it. I created a new file test, but I am even not able to see where this file is saved on my laptop. Where are the SAGE files saved on PC? How can I recover or find my file in the broken hard disk?

Thank you for your help!

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2012-07-25 10:19:27 +0100

Emil Widmann gravatar image

I am sorry I can not verify my answer myself at the moment, because I have no virtualbox installed and only a very limited internet connection which doesn't allow me to download it and test the sage ova file.

I think your files are not stored in the ova file, but when you install the ova file, there is a folder created wich contains the virtual machine files in your windows user directory. This could be e.g. C:\Users\Your_name\VirtualBox\VMs\Sage_VM1 (again I have no Windows installed and cannot check this, but I am pretty sure)

You can run different virtual machines, each one will have a seperate directory. Inside this directory there should be 2 files, the first (the small one) contains general control information like amount of ram, processor and network settings, basically everything you can modify in the virtualbox control gui. The other file is a virtual disk image (its usually large). This is basically the image of your virtual hard disk partition, it will contain fedora linux + sage and also your user data.

What is the best method to copy the old files to the new virtual machine? I don't know. Maybe there is an easy one which I am not aware of, but all I can is to point out 2 different procedures which are not difficult but might be a bit overwhelming for somebody new to VM'S and Linux in general.

1. Method: Attach the old disk image to the new virtual machine

Copy the old disk image into the folder of the new virtual machine (drag and drop in windows). In the Virtualbox control Menu you can add a new harddisk or partition to the New virtual machine (select the old file disk image). The sage vm now will have 2 hard disk partitions - the new one, from where you will boot your virtual machine, but also additionally the old image as a second virtual hard disk.

Now you should be able to access the files of the old disk image from inside the new virtual machine. Since I am not familiar enough with the sage VMs and I don't know if there is a possibility to do this from a gui interface I just can give some hints how to achieve this from the command line.

To go to the command line you will have to press Ctrl-F1. Then you probably will have to login as root to mount the old partition. So at login use "root/sage" for username/password (If this is the wrong password please look in the Sage Appliance online documentation.

Create a mountpoint for the old disk image: mkdir /media/old

Mount the old disk: mount /dev/sdb1 /media/old

(some excurs: sd_letter_number, the letter stand for the number of the harddisk and the number stands for the number of the partition, so probably the old disk image will be sdb1. You can list all available harddisk ... (more)

edit flag offensive delete link more


Thank you a lot Widmann. Actually I just solved my problem and I am happy! In fact, I copied Sage-5.0 from the broken hard disk to my laptop. Then I just run it and it works!! (i already installed Virtualbox machine on my laptop). That worked so easily!

sezar543 gravatar imagesezar543 ( 2012-07-25 19:51:33 +0100 )edit

Happy it worked ;-). The above procederes might be necessary if you you wan't to upgrade to a new virtual machine (without the built in upgrade mechanism of sage).

Emil Widmann gravatar imageEmil Widmann ( 2012-07-26 02:56:05 +0100 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools


Asked: 2012-07-23 14:31:24 +0100

Seen: 1,653 times

Last updated: Jul 25 '12