Sage Live - 511 -53

For talk and support relating specifically to Puppy derivatives
Message
Author
emil
Posts: 633
Joined: Tue 10 Nov 2009, 08:36
Location: Austria
Contact:

NEW: sagelithe smaller version

#41 Post by emil »

It always bogged me that sage is such a huge package. One reason is that it always comes as a complete developer package. With the help of the sage developers I stripped out lots stuff and created a light version of my sage pupplet., without "developer" ability, just application.

Download:
http://sage.math.washington.edu/home/emil/sagelithe

Some details:
Base distribution Lupu Quickset Edition 5.11 by shinobar

Original size of sage (uncompresssed: ca 1900 MB)
Stripped size: 770 MB (218 mB as sfs)

Size Pupplets:
SageLive - Full version, 630 MB
SageLithe - Stripped version, 400 MB

nickdobrinich
Posts: 77
Joined: Fri 06 Apr 2007, 03:29
Location: Cleveland OH USA

Sage Lithe sfs

#42 Post by nickdobrinich »

Emil,
This is one very terrific Puppy package.
Thank you very much for your efforts.

I have recently run the SageLive .iso versions with no problems.
I have also loaded and run the R and Rcmdr pets.

Today I d/l the smaller SageLithe sfs version and loaded it under Lighthouse Puppy 5G.
The sfs file was layered in but I do not know where to look for any kind of program launchers or terminal shell scripts.

Can you point me in the right direction?
Thx.

emil
Posts: 633
Joined: Tue 10 Nov 2009, 08:36
Location: Austria
Contact:

#43 Post by emil »

HI nickdobrinich,

The sage sfs is minimal, it contains no menu entries or shell start scripts.

Sage should be selfcontained and it has its own directory tree:
I put it under /sage.

so if you do

Code: Select all

cd /sage
./sage                   # it will start the CLI interface
./sage -notebook         # it will start the notebook
./sage -sh              # start sage subshell 
./sage -python            # it will start the the python from sage


You can also create a symlink in /usr/bin to sage, so you can call sage from everywhere:

Code: Select all

ln -s /sage/sage /usr/bin/sage
please also note somewhere above in this thread I report how start scripts for the sage components (maxima, R, Gap, ipython ...) are generated (command install_scripts('/usr'bin/') from sage CLI).

If you prefer Menu entries you could study and eventually copy the scripts and files from your sagelive distribution.

kind regards
emil

Edit: Sage lithe is not really so minimal. e.g if you install devx package you could try
sage -sh
R
install.packages('Rcmdr', dependencies=True)
library(Rcmdr)

it should compile and install Rcmdr for you.

emil
Posts: 633
Joined: Tue 10 Nov 2009, 08:36
Location: Austria
Contact:

Virtual Machine: vm-sage-lithe-a1

#44 Post by emil »

Since Sage is just available on Linux/Mac/Solaries, but not for windows, the usual workaround is to have a copy of sage run in a virtual machine.
The sage notebook can then be started in server mode and accessed from the browser of the host machine (or from the LAN, or even from the www if the network is setup right).

Using my stripped binaries
I managed to build a virtual machine from sage (version 4.6, size zipped 407 MB, size unzipped 468 MB). This is a reduction of roughly 60% compared to the full Ubuntu based vm image currently used.

Image
screenshot: click to enlarge

DOWNLOAD: http://sage.math.washington.edu/home/em ... the-a1.zip

-----
Technical Data (small vm image / current Ubuntu based sage vm image):
Virtual RAM: 512 MB / 512 MB
Virtual Disk size: 4GB / 8 GB
Virtual Swapspace: 512 MB (swapfile) / 1 GB (partition)
VMTools installed: no / yes
Jave RE: yes / yes
R - plotting: yes / no
Matplotlib-gui: yes-TclTk / no

hostname: vm-sagelithe
user: root
passwd: woofwoof (it's Puppy Linux)
admin password for sage notebook: sage

I have 4 failing doctests on my stripped binaries, but I accept this as a "user only" version, no development is intended in the VM. Also creating cython code is not possible.

It was hardest for me to get the network interface working between the virtual machine and the host system. I use the following startup script which uses a nonsecure httpl. Please comment what do you think, is this is possible in local network or is this insecure?

--

Code: Select all

#!/bin/sh
export SAGE_BROWSER=seamonkey
IP=$(ifconfig eth0| grep 'inet addr:' | cut -d: -f2 | awk '{ print $1 }')
IPINFO=$(printf "Use http://%s to connect to the Sage Notebook Server!" "$IP")
xterm -geometry 120x9 -e sage -notebook port=80 address=$IP require_login=False open_viewer=True &
gtkdialog-splash -text "$IPINFO" -bg lightblue -fontsize large -close never -placement bottom &
----

There is still room for size reduction, because the base distro is LupQ-511/sagelive (same as live CD), I just titied up the desktop a bit (less icons). So there are still lots of applications included which are not really necessary in the vm-image (media players, flash installed, gnumerics). Some of the applications may be useful, because there are plenty of network tools (incl. samba client / server).

Also the minimum possible virtual RAM is probably lower, around 375 MB, this could be important if the vm is to run on older, "Ram challenged" hardware.

kind regards
emil
Last edited by emil on Sun 23 Jan 2011, 18:14, edited 1 time in total.

metamorphosis
Posts: 1
Joined: Wed 19 Jan 2011, 20:07
Location: Austria

#45 Post by metamorphosis »

Hi Emil,

i think the nonsecure http is fine as long as the image is only used/run on single user windows. But "secure" it is not, i think. Depends how you define secure *gg*. Any program running on the host-pc could easily connect to that Webserver and do stuff. Of course normally there is no such program unless someone writes one and puts it there, so... Also i doubt setting up a plaintext http auth. would be much more secure because then a program running on the host with admin rights could just sniff the password..


Was curious and had a quick look at that latest sage-lithe image.
Don't have vmware installed at the moment but kvm, so i decided to try loading it with that.

Turns out with a little trial and error of cmdline parameters it is running fine:

Code: Select all

qemu-kvm -enable-kvm -drive file=vmsla1-0.vmdk,if=ide -m 1024 -vga vmware -net nic,model=i82551 -net user,hostfwd=tcp::8080-:80
Now i know it's not really necessary to run sage in a VM on a linux PC, but i thought this could be useful if someone wan'ts to do some testing or development work on that image on a linux host where kvm is installed.

emil
Posts: 633
Joined: Tue 10 Nov 2009, 08:36
Location: Austria
Contact:

#46 Post by emil »

Servus methamorphosis :D ,

I have no network experience, and I also think as long as there are only trusted users in the LAN it is fine. To see the VM from "outside, like www" I think it have to be routed somehow (I really know nothing about networks).

The problem could be, if you log in to the Sage Notebook you have a full programming environment, running currently as root, so you could (maybe?) do all sort of stuff there. I know there is the possibility to run applications in puppy as different user (like kirk does in Fatdog, browser runs as user spot).
This could be a possibility to restrict damage, but currently I just have a vague idea about all possible implications!

So thanks for kind feedback - another question. You are running qemu with kvm - how is the speed compared to vmware or Virtual box?

Thanks for the startup-command for quemu - this line definitly qualifies for higher arcane commandline magic!

8) emil

HAHA: 1.post - welcome to puppy forum!

User avatar
Aitch
Posts: 6518
Joined: Wed 04 Apr 2007, 15:57
Location: Chatham, Kent, UK

#47 Post by Aitch »

Hi emil....

I don't know if it's connected to your SageLive, but user L18L found sage-4.6-32bit-Puppy_Linux_Lupu.sfs at

http://www.mirrorservice.org/sites/www. ... index.html

In response to my post about [dismal] Puppy mirroring

http://www.murga-linux.com/puppy/viewtopic.php?t=64859

It may be for Lupu users only, I don't know?

Aitch :)

emil
Posts: 633
Joined: Tue 10 Nov 2009, 08:36
Location: Austria
Contact:

Sage for puppy on the official Sage servers

#48 Post by emil »

Hi Aitch,
this is a Sage package compiled in November. It was compiled at 5.11. For other puppies: Sage is usually compiled from source. One needs the devx and gfortran installed.
I am sorry to say that, but given the fast release cycle of sage and the multitude of different puppies, it I find it next to impossible to support up-to-date packages for a broader range of puppies.

In the meantime there is already a new release (4.6.1). For 511 users, who dont need developement capabilities I recommend the "sagelithe" package which is only 218 MB (unofficial).

Emil

emil
Posts: 633
Joined: Tue 10 Nov 2009, 08:36
Location: Austria
Contact:

Purity

#49 Post by emil »

Image
from http://xkcd.com/435/

couldn't do any real work on sagelive derivative latly. Maybe there will be an update to a new sage version in autumn.

ICPUG
Posts: 1308
Joined: Mon 25 Jul 2005, 00:09
Location: UK

#50 Post by ICPUG »

Hi Emil,

That's funny - and probably confirms the mathematics stereotype to the rest of the world!

Now where does engineering appear on this scale?

You update SageLive when you are able - less frequent updates can be an advantage sometimes!

I was playing with the Knoppix 6.5 DVD yesterday and noticed a maths package in the education section of the disk. I would tell you what it was called if I was on my own machine now! It was a gui based package which I quickly got to do a simple indefinite integration (x^3). Trying to find the name of the package just now I find there is a www.knoppix-math.org website that maybe relates to a Knoppix disk for mathematicians. Don't know cos my work's internet policy will not let me see the website! Lookin at the Google cache shows me it is mainly a Japanese project although an English version has recently been released.

Take care.

User avatar
hayden
Posts: 61
Joined: Thu 14 Sep 2006, 01:49
Location: New Hampshire USA

Knoppix math.

#51 Post by hayden »

There was a Knopix spinoff called Quantian on DVD. The programs are a bit dated now but if nothing else it is useful for finding a huge number of math. and technical apps. Some later versions of Knoppix included many of these but then Knoppix went on a diet to get back on a CD.

User avatar
edoc
Posts: 4729
Joined: Sun 07 Aug 2005, 20:16
Location: Southeast Georgia, USA
Contact:

#52 Post by edoc »

Anyone tried this with Fluppy?

ZMAP looks like a good Linux alternative to MS-dependent Earthquake3D, but I could not find any reference to it on the SAGE page - so I don't know if it or any other MATLAB-dependent apps will work with SAGE.

Has there been a discussion as to why Sage was chosen over Octave 3.3?

I don't know the difference, was only curious ... as always!

I read the following here:

http://www.gnu.org/software/octave/

"The Octave language is quite similar to Matlab so that most programs are easily portable."
[b]Thanks! David[/b]
[i]Home page: [/i][url]http://nevils-station.com[/url]
[i]Don't google[/i] [b]Search![/b] [url]http://duckduckgo.com[/url]
TahrPup64 & Lighthouse64-b602 & JL64-603

User avatar
hayden
Posts: 61
Joined: Thu 14 Sep 2006, 01:49
Location: New Hampshire USA

Sage and Octave

#53 Post by hayden »

Well Sage is actually a wrapper for about 100 programs which is why it is so humongous. You can find the contents at
http://www.sagemath.org/links-components.html

So maybe the question is why Sage did not use Octave for its linear algebra functionality. In general, Octave would not be competitive with Sage as it has much more limited functionality. If you want to do a LOT of the things Sage does it is worth the disk space and the integration is a feature. If you only want to run Matlab code you could install Octave in a lot less space and you might find the Sage interface gets in your way.

User avatar
edoc
Posts: 4729
Joined: Sun 07 Aug 2005, 20:16
Location: Southeast Georgia, USA
Contact:

#54 Post by edoc »

Hmmm, I glassed-over in math when they went and mixed letters and numbers!
;-)

OK on the different purposes - will have to give that some thought.

Perhaps someone has, or is, developing an earthquake mapping app for SAGE - or is porting ZMAP ...

Thanks!
[b]Thanks! David[/b]
[i]Home page: [/i][url]http://nevils-station.com[/url]
[i]Don't google[/i] [b]Search![/b] [url]http://duckduckgo.com[/url]
TahrPup64 & Lighthouse64-b602 & JL64-603

emil
Posts: 633
Joined: Tue 10 Nov 2009, 08:36
Location: Austria
Contact:

Upgradet to sage 4.7.1

#55 Post by emil »

Actually I am going to make an upgrade of the Sage Live CD

Release Candidate (should be working OK)
http://www.google.com/url?sa=D&q=http:/ ... 47-rc1.iso

quote from the sage-devel list
I updated the current Live CD image.

Changes:
+ Sage 471 compiled with SAGE_MATPLOTLIB_GUI="yes" and
SAGE_FAT_BINARY="yes"
+ new html doc (english)
+ new feature: sfs_load to load/unload additional modules "on the fly"
+ more Bling: added some wallpapers

I kept the base distribution with a Linux kernel 2.6.33.2.
Download release candidate:
http://boxen.math.washington.edu/home/e ... e-511-47-r...
also soon on www.mydrive.ch (user: download@sagelive; pwd:
mathematics)

Please report if there are problems. If there are no serious bugs I
will ask Harald Schilly to update the download servers in a few days
with the new version.

I will also make an exe installer, because the bug with installation
in 64 bit Windows should be solved.
I decided to stick with shinobars 511 base. There are many nice features included (boot to desktop, enhanced foreign language support, PupSaveConfig, Firstrun, swaptool). Beside the new sage package I just added the awesome sfs_load "on the the fly" - and some nice wallpapers.

I had also a look at the wary quickset edition as base. Pro was its a longterm support, con was the larger package base for ubuntu and the amount of work I had already put into it.

New slacko would also be nice, but boot to desktop is a strong argument.

The sage included is a complete "distro build", I have a rough build script

Code: Select all

#!/bin/sh
# script to build sage, 

# preparations
# be sure that Tcltk is installed (needed for R plotting)
# also install a Latex package (sage needs "Latex", so make a symlink from "latex")
# To compile you need to download the devx sfs Package for sagelive
# defaultbrowser http://boxen.math.washington.edu/home/emil/doc/html/en/ADD_SOFTWARE_devx.htm &
# Also a fortran compiler is needed (check with gfortran)

# download latest sage sourcecode from the sage server
# defaultbrowser http://www.sagemath.org/download-source.html
# tar xvf the package

# put this script and the zipped sourcecode in a "build directory" on a physical drive
# sage is big you will need 4 GB disk space
# e.g. choose /mnt/home or /mnt/sda2
#
# then run the script
#
#

BUILD_DIR=sage-4.7.1
export SAGE_MATPLOTLIB_GUI="yes"    # This compiles python in a way so you can use matplotlib printing outside sage
export SAGE_FAT_BINARY="yes"        # Compiles without specific processor optimisations, i.e. for the widest possible range of processors
cd $BUILD_DIR
make								# compiles the package (could last hours)
./sage -testall						# runs the testsuite (could last more hours)
./sage -bdist 						# created the binary distribution directory tree (Needs 2GB free diskspace)

# Then you have the distro build in./dist/sage-4-7.1-fat
# to create a sfs package run e.g. mksquashfs ./dist/sage-4.7.1-fat 

sage-4.7.1
sage has again increased in size since the last year, I think in the not so distant future it will not be possible to put it in a 700 MB iso.

any feedback welcome,
emil

emil
Posts: 633
Joined: Tue 10 Nov 2009, 08:36
Location: Austria
Contact:

Windows exe installer

#56 Post by emil »

small changes
+ sage notebook startup improved (solved browser error)
+ sage autostarts at firstrun.
I made a new windows exe installer
http://boxen.math.washington.edu/home/e ... 7-beta.exe
Last edited by emil on Sun 23 Oct 2011, 21:58, edited 2 times in total.

ICPUG
Posts: 1308
Joined: Mon 25 Jul 2005, 00:09
Location: UK

#57 Post by ICPUG »

Nice to see development continuing on this project.

My download speed is half what it should be these days so I am reluctant to download large isos at the moment to test. I see you are getting some feedback from the Sage groups anyway.

I agree with your preference for 'boot to desktop' if it is possible.

emil
Posts: 633
Joined: Tue 10 Nov 2009, 08:36
Location: Austria
Contact:

#58 Post by emil »

New version is out;

changes to rc:
+ autostart sage server at firstrun
+ sage notebook starts with require_login=False open_viewer=True
+ sage admin preconfigured: password: sage
+ this fixes the localhost:8000 not found bug which plagued all earlier versions

release announcement here

emil
Posts: 633
Joined: Tue 10 Nov 2009, 08:36
Location: Austria
Contact:

New Sage Lite VM server (iso and virtual image)

#59 Post by emil »

Hi -
First some Updates on this project,
I registered this on distrowatch (just waiting list):
http://distrowatch.com/weekly.php?issue=20111031
Sneakylinux made a review of Sage Live CD on Youtube:
http://www.youtube.com/watch?v=8HEtwAhyJak
I think this was triggered by the distrowatch entry, Sage Live CD on Softpedia:
http://linux.softpedia.com/get/System/O ... 5608.shtml
Sage/Sage Live CD used in University teaching in Graz (2nd largest city in Austria)
http://www.math.tugraz.at/~ziegler/Comp ... Mathe.html

Ok now about the real beef:
I worked on the small version with the goal to create a small preconfigured multiuser sage server running as a restricted user. I also removed some of the applications from the stock puppy. I got the smallest Sage Live CD iso until now (392 MB):

Image

As you can see above, I invested the time for some eye candy (wallpaper, special GTK theme).
So this is beta because of the reduced sage (maybe some part of it is broken and I am still not aware of it) and of the new server functionality ( I am really no network pro). But it should be nice for demo purposes, or a quick class (introduction), because you can put in the live cd/usb and then have access to the server with all the other machines of the network (notebook interface in the browser).

http://boxen.math.washington.edu/home/e ... rverb1.iso

For longer use it might be a good idea to shift the /home folder (which has all the sage notebook user data) on a physical drive (like /mnt/home) and symlink it to /home.

I also made a special built virtual Image (tested in virtualbox). This is a full install preconfigured with 500 MB RAM and "bridged network settings". This is especially suitable if you want to use it on a windows machine, but it should also be an option for sysadmins to have an easy and secure (sandboxed) way to install a sage server on their network. For full use it will be necessary to increase the allocated ram of the vm, maximum disk size is 20 GB, this should do for a while.

http://boxen.math.washington.edu/home/e ... vms-b2.ova

Some technical details:
I kept the base 511 - I guess I leave this stable for another year.
You can use all software packages for Lupu 511. maybe install octave and have also a usable octave server in the network?
This uses my cutdown Sage 4.6 package from spring - If you need the latest Sage (4.7.2) this is not for you. Also if you need cython code or want to do developement this will not work.
Restricted users: I needed to make busybox suid, made /dev/null globaly writeable (some other file in /dev/ too, but I forgot the name) to have the restricted user work properly. I also found that sfs load on the fly doesn't work properly with multiusers (I had a version where I had a separate sage sfs package), but if you load the sfs with the Bootmanager it is working fine.
I didn't manage to install the VirtualBox guest additions properly, so don't know if anybody managed that in 511?

I would very much appreciate any feedback about the functionality of the small sage package and also if the "easy setup server" is working as expected.

thanks
emil

User avatar
hayden
Posts: 61
Joined: Thu 14 Sep 2006, 01:49
Location: New Hampshire USA

Emacs

#60 Post by hayden »

Thanks again to Emil for all his work on this.

I am using a 700Mb SAGELive ISO dated 31 October -- not sure if that is creation date or download date. Numbers are 511-47. I noted some minor problems with Emacs. It is in the menu system but nothing happens if I select that menu option. At the CLI, typing "emacs" seems to run MicroEmacs. So I installed the PET for real Emacs and had to fiddle around to get that to run instead of MicroEmacs when I type emacs at the CLI. (Real Emacs also creates a menu entry but it too fails to launch anything.) Real Emacs tries to start but then complains about a mssing dependency - libjpeg.so.8 which is not available in the Puppy Package Manager. (Not sure why a plain text editor needs a graphics library to run.)

Even more minor I found the grey background in the terminal made text hard to read. I spend LOTS of time in a terminal connected to a UNIX machine in another country. My fix was to install ROXterm which I recommend for this distro which makes heavy use of CLI programs. It also lets you cut and paste in the terminal window.

I remastered this with all the options installed and it's about 1Gb. I will continue to play with it. An interesting competitor is Poseidon which looks very nice but the translation into English is only at the top level. Get below the surface and English is gone!-( For example, the package names are in English but not the descriptions! Likewise the boot options.

I also have ye olde Quantian and a couple Puplets I made myself. I think what kills these is that they get half done and people run out of steam and the project dies. I have some TIME available to help thoguh my expertise is more toward the math. apps. and writing documentation than computer stuff per se. (I don't think I've compiled a program since 1973.)

Post Reply