Author Topic: LTSP FAT Client applications  (Read 7219 times)

kragsterman

  • Zen Apprentice
  • *
  • Posts: 6
  • Karma: +0/-0
    • View Profile
LTSP FAT Client applications
« on: September 23, 2012, 01:21:22 pm »
Hi there!

 I'm a long time user of LTSP.

I've been waiting for LTSP on Zentyal for a long time now, and I'm now very happy for the inclusion! And not only inclusion, you seem to have made up a lot of nice improvements on administration of the clients!

 I've yet not tested it, but it really looks promising! I will test it in the nearest future, and give it a review from my point of view.

 I've got a couple of questions, though:

 I intend to run several chroot's, like 32 bit thin client, and 64 bit fat client, and one or more special purpose chroot environments.

 Is it possible to have several chroot's of the same arch? I don't see a naming function in the creation page? Or are they just given a random name? I suppose I can change that in the config files if so?

In the FAT Client chroot, you have a feature to include applications to be run locally. How are these app's chosen? Are they only standard app's, or is it possible to include whatever...? I know I can include app's with just apt-get install in chroot, but perhaps this adds some other stuff as well?

 Thanks in advance, this is really good work...!!!

Regards Johan

jsalamero

  • Zentyal Staff
  • Zen Hero
  • *****
  • Posts: 1419
  • Karma: +45/-1
    • View Profile
Re: LTSP FAT Client applications
« Reply #1 on: September 23, 2012, 04:54:27 pm »
Hi Johan,

you can only create one profile per architecture, localapps are only meant for thinclients, doesn't make sense on fat clients, as there, everything is run on the terminal.

Thanks for your feedback!!

kragsterman

  • Zen Apprentice
  • *
  • Posts: 6
  • Karma: +0/-0
    • View Profile
Re: LTSP FAT Client applications
« Reply #2 on: September 23, 2012, 08:43:28 pm »
Okay, then I have to build chroot's anyway with ltsp-build-client...not a big deal...

But are the clients built with this ltsp script  shown in the image repo? I guess not..?

Okay, so on the fat clients everything is run on the clients...? So when the fat client chroot is built, does it include all applications that is installed on the server? Or how does it choose the app's?

 Regrds Johan

FarquahrWindsor

  • Guest
Re: LTSP FAT Client applications
« Reply #3 on: September 24, 2012, 04:54:37 am »
Its really strange how zentyal have installed ltsp as there is no difference in a fat image or thin image.

I think it would be a great addition to be able to have a list of images and get hold of the --client-desktop operator.

ps in the ltsp-build-client command the --fat-client directive just builds the current desktop the way to choose fat or thin is just a directive in the .conf file.
 

Neru

  • Zen Monk
  • **
  • Posts: 58
  • Karma: +6/-0
    • View Profile
Re: LTSP FAT Client applications
« Reply #4 on: September 24, 2012, 06:09:02 pm »
Hello kragsterman,

you can install additional applications in an image like "local apps". It doesn't matter wheter it is a thin or a fat image.

For the moment, there is only one chroot for arch (actually 2, one for thin and another one for fat clients), but you can create as many configuration profiles as you want.

Regards

kragsterman

  • Zen Apprentice
  • *
  • Posts: 6
  • Karma: +0/-0
    • View Profile
Re: LTSP FAT Client applications
« Reply #5 on: September 28, 2012, 08:29:58 pm »
Unfortunately, it doesn't seem to work with building additional thin or fat client images. It works fine with the first one, but second/third or forth doesn't build. Returns an error saying ""error building client". It was my second install, I did things a little bit different, but the error of building additional client images remains the same.
 The client environments gets installed, in the right place, but not the images.

 Anyone got ideas...?

Regards Johan

FarquahrWindsor

  • Guest
Re: LTSP FAT Client applications
« Reply #6 on: September 29, 2012, 11:02:40 am »
I am going to check the LTSP and install now.

I found that there was a problem on booting an image after creation and things needed a reboot.
Is it still the same after a reboot

I found quite a few probs with the LTSP implementation but it would be good to share and see how others are going.

My finding before http://pastebin.com/mSXnxCTv

Might of been fixed dunno but testing this morning.

Also I have a feeling that the env of LTSP_HANDLE_DAEMONS=false might be staying that way until reboot.

Going to check this things today and report.


kragsterman

  • Zen Apprentice
  • *
  • Posts: 6
  • Karma: +0/-0
    • View Profile
Re: LTSP FAT Client applications
« Reply #7 on: September 29, 2012, 11:23:18 am »
Hi!

I'm also on to it now...

I'm testing to build the client(s) with ltsp-build-client. I run it  a couple of times now, with different parameters, and I think I got it right now...

Will be back...

Rgrds Johan

FarquahrWindsor

  • Guest
Re: LTSP FAT Client applications
« Reply #8 on: September 29, 2012, 11:28:22 am »
Yeah same here :)

Just going to run through some things and do a style that suits myself so here is Zentyal LTSP for Dummies :)

Firstly building images takes a bit of time if you do build an image you can go on to your desktop and eventually it does stop building shame the progress bar doesn't move.

One thing is that building does take time and whilst building Zentyal sets a redis variable to say the system is building an image. This needs to be retained at a session level as a reboot will retain this and not have a script to end and clear it. Or stop you rebooting at this time.

I will post a tiny perl script to clear on pastebin http://pastebin.com/Zq9iJzzR

PS
[EDIT] the path is from memory and with me thats a dangerous method but hey if its wrong please say.
« Last Edit: September 29, 2012, 12:15:17 pm by FarquahrWindsor »

robb

  • Guest
Re: LTSP FAT Client applications
« Reply #9 on: September 29, 2012, 12:40:32 pm »
Looks useful enough to add to the module. thnx for that.

jacalvo, is this an idea to implement in the thin client module? Or do you have other plans to represent the building time?

FarquahrWindsor

  • Guest
Re: LTSP FAT Client applications
« Reply #10 on: September 29, 2012, 12:46:55 pm »
I am just doing things my way which is a bit arse-face which is a northern english term blunt but probably makes sense.

I am doing an LTSP scenario and trying some techniques.

So standard ubuntu 32bit ISO apt-get update and apt-get upgrade on a bog standard install with just ssh server installed.

There are two trac entries and the later seems to miss the --key operations.

Use http://trac.zentyal.org/wiki/Documentation/Community/Installation/InstallationGuide

Zentyal 3.0 packages

For Ubuntu 12.04 (Precise). You should install the server edition.

Add to your /etc/apt/sources.list:

sudo nano  /etc/apt/sources.list
deb http://ppa.launchpad.net/zentyal/3.0/ubuntu precise main
deb http://archive.zentyal.org/zentyal 3.0 main extra

In order to authenticate the packages in the PPA and Zentyal repository you can import its public key with the following command:

sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 10E239FF
wget -q http://keys.zentyal.org/zentyal-3.0-archive.asc -O- | sudo apt-key add -


sudo apt-get update is important as it well check things are right with the repos and make them fresh before you install zentyal.

sudo apt-cache search zentyal

so to get my minimum zentyal going I will

sudo apt-get install zentyal-core
sudo apt-get install zentyal-software


Keep the SQL root password blank for now and the default for https for the admin gui.

Afterwards from the initial boot screen you should be able to ssh and https://server-ip should work.

Then choose to proceed anyway because we know this is our self certified web-gui



Because I usually evalute on win7 putty or ssh into the dynamic ip and hopefully you should have an easy copy and paste interface for the above commands.
« Last Edit: September 29, 2012, 03:24:46 pm by FarquahrWindsor »

kragsterman

  • Zen Apprentice
  • *
  • Posts: 6
  • Karma: +0/-0
    • View Profile
Re: LTSP FAT Client applications
« Reply #11 on: September 29, 2012, 01:16:45 pm »
Hi again!

Hmm, the fat client image woun't bulid in the GUI. It works with the 32- and 64-bit thin images, but not with either 32- or 64-bit fat...

I also tried with building client's with ltsp-build-client --fat-client with different other parameters, but that didn't work either.. It complained over various options like --chroot or --arch, said it didn't recognize them...? I tried also --base, and that one worked, but no fat image...

 So, can you(Zentyal team) tell me what changes you have made to ltsp to get this not to work...?

I saw your directories and fiies under /usr/share/zentyal-ltsp/ , but I don't really got much out of them.

I'm thinking of something that showed up during my attempt to install through the console: It complained over not finding packet zendesktop...?

I'll be back...

Rgrds Johan

FarquahrWindsor

  • Guest
Re: LTSP FAT Client applications
« Reply #12 on: September 29, 2012, 02:17:41 pm »
Its  strange thing but the build commands are not the place for fat-client directives.
The conf files is it ? /var/lib/ltsp ? forgot where they are but you can simulate a fat client with the general options which are conf directives

kragsterman

  • Zen Apprentice
  • *
  • Posts: 6
  • Karma: +0/-0
    • View Profile
Re: LTSP FAT Client applications
« Reply #13 on: September 29, 2012, 02:31:58 pm »
There are many .conf files, which one are you refering to?

I don't want to simulate a fat client, I want true fat clients. In a normal ltsp environment(for instance ubuntu), I can build as many fat and thin client images I'd like to, and set them up to run different software and boot to different hardware. I thought Zentyal had successed to do this in a GUI environment, but I guess it isn't ready yet...

 But then I want to be able to do it the normal ltsp way, but that seem to be impossible too...?

So, how do you folks want to do it...?

Regards Johan

FarquahrWindsor

  • Guest
Re: LTSP FAT Client applications
« Reply #14 on: September 29, 2012, 02:37:16 pm »
The conf flies are located in corresponding image dirs it will be something like /var/lib/ltsp/i386 and fat-i386.
My memory is woefull but basically its the general options.

I spent ages looking around and the best place is sudo apt-cache search ltsp
and a sudo apt-get install ltsp-docs should of been an obvious start point but hey I did say I was a dummy.

In the build-client options which need to be set on image creation the --fat-client directive makes the image distro the same as installed and if you wish to include the zenbuntu-desktop then the following is required.

ltsp-build-client --arch $arch --purge-chroot --copy-sourceslist --apt-keys /etc/apt/trusted.gpg --chroot $chroot --fat-client

The --copy-sourceslist --apt-keys /etc/apt/trusted.gpg options will bring in the ones you have added for the zentyal ppa and archive.

The scripts for running zentyal-ltsp are in /usr/share/zentyal-ltsp/

The above is a hack of the normal build-image script.
What it will do is copy your servers source.list and also the keys automatically and the --fat-client directive builds your current DE
This way you don't have problems of build faults.

        EBox::Sudo::root("echo `date` $buildCmd >> /var/log/zentyal/ltsp.log");
        EBox::Sudo::root("$buildCmd >> /var/log/zentyal/ltsp.log");


I also like to get a bit more in the log and seeing the command is sort of usefull

Also interestingly in the general options put a value pair in the extra options.
LTSP_FATCLIENT and True

Hey presto is the word on that one.

Going back to the build-client script
 --chroot $chroot --fat-client-desktop lubuntu-desktop

Is another nice option where you can choose another desktop from the ubuntu repos

also the --distro options has a few supported distro's maybe older versions for limited hardware in the ltsp/scripts and plugins dirs

I had a bit of a hack with the update-image script and this keeps the kernels to a singular image and also bangs out an interesting log for having a view at the processes involved.

logging in update-image
#!/usr/bin/perl -s
 
use strict;
use warnings;
 
use EBox;
use EBox::Global;
 
if (scalar @ARGV == 2) {
    my $arch = $ARGV[0];
    my $fat  = $ARGV[1];
    my $chroot = ($fat ? "fat-$arch" : $arch);
    if ( -f "/opt/ltsp/images/$chroot.img" ) {
        EBox::init();
 
        my $ltsp = EBox::Global->modInstance('ltsp');
 
        $ltsp->st_set_string('work', 'update');
        print "Updating $chroot image...\n";
 
        my $CHROOT_DIR = "/opt/ltsp/";
        EBox::Sudo::root("echo `date` chroot $CHROOT_DIR$chroot mount -t proc none /proc >> /var/log/zentyal/ltsp.log "
                         . "&& chroot $CHROOT_DIR$chroot mount -t proc none /proc >> /var/log/zentyal/ltsp.log "                         
                         . "&& echo `date` chroot $CHROOT_DIR$chroot apt-get update >> /var/log/zentyal/ltsp.log "                     
                         . "&& chroot $CHROOT_DIR$chroot apt-get update >> /var/log/zentyal/ltsp.log "
                         . "&& echo `date` chroot $CHROOT_DIR$chroot env LTSP_HANDLE_DAEMONS=false apt-get upgrade -y >> /var/log/zentyal/ltsp.log "
                         . "&& chroot $CHROOT_DIR$chroot env LTSP_HANDLE_DAEMONS=false apt-get upgrade -y >> /var/log/zentyal/ltsp.log "
                         . "&& echo `date` chroot $CHROOT_DIR$chroot autoremove -y >> /var/log/zentyal/ltsp.log "
                         . "&& chroot $CHROOT_DIR$chroot apt-get autoremove -y >> /var/log/zentyal/ltsp.log "
                         . "&& echo `date` chroot $CHROOT_DIR$chroot clean >> /var/log/zentyal/ltsp.log "
                         . "&& chroot $CHROOT_DIR$chroot apt-get clean >> /var/log/zentyal/ltsp.log "
                         . "&& echo `date`  umount /opt/ltsp/$chroot/proc >> /var/log/zentyal/ltsp.log "                       
                         . "&& umount /opt/ltsp/$chroot/proc >> /var/log/zentyal/ltsp.log "
                         . "&& echo `date` ltsp-update-kernels $CHROOT_DIR$chroot >> /var/log/zentyal/ltsp.log "
                         . "&& ltsp-update-kernels $CHROOT_DIR$chroot >> /var/log/zentyal/ltsp.log "
                         . "&& echo `date` ltsp-update-image --image-only --arch $chroot >> /var/log/zentyal/ltsp.log "                       
                         . "&& ltsp-update-image --image-only --arch $chroot >> /var/log/zentyal/ltsp.log");
        $ltsp->st_set_string('work', 'none');
    } else {
        print "/opt/ltsp/images/$chroot.img does not exist.\n";
    }
} else {
    print "Usage: update-image arch fat?\n";
}

 
lsb - Linux Standard Base 4.0 support package
if you run ltsp-info
it will tell you no modules loaded
apt-get install lsb

I am not really sure of the relationship between ltsp and LSB but if there are problems the LDM will report without a silent reboot.

Also restarting ndb-server doesn't sometimes seem to be enough and just so I know where I am I have rebooted zentyal on build or update.
sudo reboot !!! After they have finished.
« Last Edit: September 29, 2012, 03:04:57 pm by FarquahrWindsor »