Okay. I think I just finished all the steps I wrote in my original post. Overall, it was not terribly difficult, but, it was not completely straightforward, either. FYI, my linux skill is not very sophisticated, but, not too bad compared to, say, my colleagues in my department, whatever that means... In fact, I never owned a linux machine myself, but, I remember certain things when I had an account in a Unix machine and used in for my C course back when I was an undergraduate... (in the 90s).
Anyway, I will summarize my experience based on the steps I outlined in my previous above. Mostly, I benefited the most from the paragraph "securing the sage notebook" at http://wiki.sagemath.org/SageVirtualBox and the help menu ("notebook?" from sage prompt). 1. Create an account, say "server", in the machine I'm running sage notebook. Create another (or more) accounts, say "worker", (or "worker1", "worker2", etc,.). --> The instruction at http://wiki.sagemath.org/SageVirtualBox says $ sudo adduser nbuser $ sudo addgroup sageusers $ sudo adduser ondrej sageusers $ sudo adduser nbuser sageusers (here, replace "ondrej" with "server" and "nbuser" with "worker"), but, I found out this depends on the linux system you're using. I'm using opensuse, and it didn't like adduser, so, I ended up using the YaST tool to complete this step. 2. Set up ssh keys so that "server" can ssh in to "worker" without password. --> This was the most tricky to me. The goal is to set up the ssh keys so that, when you do ssh wor...@localhost from "server", you can log in without requiring a password, as is explained in the help menu ("notebook?" from sage prompt). To explain the help menu a little bit, * (From "server") Type `ssh-keygen’ * Put the content of ~/.ssh/id_rsa.pub in the "server" account in the file .ssh/authorized_keys of "worker" account. (You must create this file, if it doesn't exist already.) After this step is done, try, from the "server" account, ssh wor...@localhost and make sure you log in without password. Also, "worker" should know the path where sage is installed. * To get the permissions of files and directories right, I just followed the steps in the wiki page above, which says, $ mkdir nbfiles $ chmod g+w nbfiles I'm not sure if I got this right (see my question below). 3. Run an instance of notebook from the account "server", but let the "worker" account run the worksheet process by using the 'server_pool' option. 4. Don't forget to run the server securely by choosing the option 'secure=True'. --> These two steps are just to start a notebook instance with the right options. The instruction at the wiki page is quite good; just modify the options to meet your needs. Here's a question. After I started the sage notebook instance from the "server" account, I see that there are two directories under ~, which are drwxrwxr-x 2 server users 4096 2010-01-14 10:54 nbfiles drwxr-xr-x 3 server users 4096 2010-01-14 15:16 nbfiles.sagenb The first one is the one created in step 2 above, and the second one seems to be created automatically from the notebook instance. And, I found that the nbfiles directory is empty! Was it necessary after all? Or, did I do something incorrectly? Do the permissions there look alright? On Jan 7, 7:28 pm, "Dr. David Kirkby" <[email protected]> wrote: > William Stein wrote: > > On Thu, Jan 7, 2010 at 9:10 AM, Jason Grout <[email protected]> > > wrote: > >> William Stein wrote: > > >>> Yes, it sounds completely right to me. Let us know if the above steps > >>> lead you to any trouble. And if they work, we should clearly add them > >>> as a summary to some documentation somewhere. > >> I agree. I just had someone email me privately with the same sort of > >> question, "How do I set up a campus server". I was going to post, but > >> Byungchul has outlined it pretty well. > > >> How about a new "Administering Sage" book added to the documentation? > >> Setting up a campus server, security concerns, etc., could be noted in it. > > > Maybe we can rename the "Installation Guide" to "Installing and > > Administering Sage"? > > > William > > I don't see anything wrong with just "Installation guide" myself. > > Perhaps windows users expect to install it and it work immediately. Unix users > will know that software often requires some configuration. > > But if not, "A Guide to Installing and Configuring Sage" seems a bit less > intimidating than "administering" > > I must admit, I found the information on starting the server very spartan. > I've > run SSH servers, web servers, webMathematica severs ... but nowhere I have I > found the documentation so sparse. (BTW, webMathematica was a lot more hassle > to > install that Sage. I've not done it recently, so perhaps WRI have improved it. > But you needed to be pretty clued up to install that). > > I imagine a lot of people will want to run Sage on a LAN, but not open to the > world. I've built it on one of my machine at 192.168.1.15, and want to be able > to access it from anywhere on the 192.168.1.x network, but not have it open to > the world.
-- To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/sage-support URL: http://www.sagemath.org
