[Debian] Running Debian in a chroot
This is a technical discussion thread about running Debian in a chroot. Please post questions about custom setups or technical problems here.
UPDATE, AUGUST 10 2008: I have posted the newest versions of the chroot scripts (/sbin/debian, /sbin/closechroot, /sbin/synchroot, /usr/bin/debbie) and the chroot config file (/home/user/.chroot) in this post. You can use these scripts to set up your own custom chroot solution. If you just wish to have the applications that Debian gives you (OpenOffice, Firefox, etc) without the hassle, use the Easy Debian package. UPDATE, JULY 3 2008: The post with the first installable .deb files and a link to the first version of the chroot image file is here on page 9, and there is an empty 1GB image file with some cool ideas for other chroot options a few posts later, here. I posted a smaller image file (730MB) with all of the applications installed a bit later, here. Lastly, I posted a 1GB image file with only minimal applications installed here, so that those who want to experiment with installing lots of different apps can have more "play-space". The rest of the thread is a bunch of hardcore Debian chroot enthusiasts trying to get stuff working and keeping each other up to date. Oh yes, and one very cool video. ORIGINAL POST FOLLOWS: Hi all, I have a wiki entry, Running Debian in a chroot This method allows you to install and run any of the thousands of applications, including things like Gimp and OpenOffice, compiled for the Debian armel port, without rebooting your tablet. Many of them run under the default OS, but you may need to use penguinbait's KDE to run some of the apps, because they are designed for a desktop OS and they have problems like dialog boxes that don't fit on the standard tablet operating system's screen. I have posted about this in various threads, but I wanted to start a new thread so that people can discuss this in one place and propose better ways to do it. I would love to see a simple, newbie-friendly way to set this up so that anyone can install and run Debian apps with a minimum of hassle. This thread might help to make that happen. Also, if you find Debian apps that work particularly well, apps that totally crash the system, or tricks for getting certain Debian apps to work on the tablet (eg. make sure you install esound support to get sound working on several apps), you can report your findings here. EDIT: The "Discussion" tab on the wiki now links back to this thread. Nice. |
Re: Running Debian in a chroot
Hello qole my friend,
in order to avoid fiddling with passwordless ssh, I changed the /usr/bin/debbie script as follows: Code:
#!/bin/sh This seems OK BUT I haven't been able to make hildon menu items work. If your menus do their job indeed, would you please try this modified script to see if it makes them not functional? Thanks |
Re: Running Debian in a chroot
I have added a bit to the wiki from Benson, he pointed me to using visudo to make it possible to run anything as root just by typing sudo <command>, so now I just make the exec line in my menu item look something like:
Quote:
You can make the "debbie" script just say "sudo debian hilda $*", that works too. I found Personal Menu to be great for running these programs too; you don't have to mess around with a text editor and .desktop files. Also, there's a "run as root" checkbox. |
Re: Running Debian in a chroot
Xnest won't behave, installed, and it's not there...
|
Re: Running Debian in a chroot
Xephyr works. Try it instead of Xnest.
|
Re: Running Debian in a chroot
This is great news.
I installed xserver-xephyr on the debian chroot, then started xephyr in fullscreen as display :1. Then in the Debian prompt exported display to :1 Then started xfce4-session. Ta-dah! Full screen xfce4 (with abiword, openoffice and all the band) along with hildon-matchbox and those other odd things. Two worlds together! I am verrrrry happy :-) Now I need a new 8gigs transflash. The one I had from Sandisk was fridged by the tablet and I was never able to restore it. My present 6gigs has become insufficient for that debianosaurus. |
XFCE4 in Xephyr on top of OS2008
Quote:
But, if you want to go the two-WM route, I suggest looking into the VNC method: VNC METHOD
This method has the following advantages:
However, for anyone interested in getting this to work with Xephyr (come on, you know you do), within Debian you'll need to: XEPHYR METHOD Code:
apt-get install xserver-xephyr Then, I suggest a little script (/usr/bin/xephce4 ? ;) ) with something like the following: Code:
#!/bin/sh Code:
sudo debian xephce4 Advantages of this method:
http://farm3.static.flickr.com/2059/...4603f6b4d1.jpg Quote:
|
Re: Running Debian in a chroot
Could one of you guys post a quick recipe for getting Abiword to work through Debian on maemo and/or KDE?
If so, thanks! |
Re: Running Debian in a chroot
Once you have your chroot scripts set up as I describe in the wiki, you go into Debian and "apt-get install abiword", and abiword should run from the Debian prompt. Then you just have to run "sudo debian hilda abiword" from a maemo terminal or put that line into a .desktop file.
Could you be more specific as to what your problem is? I can give better help if I know what's wrong. |
Re: Running Debian in a chroot
From my approximate evaluation, calling openoffice or abiword in hildon windows (the "debbie abiword" method) is much quicker than calling them under xfce4 in a Xephyr window.
At present I don't know if that depends on Xephyr or on xfce4. I'll experiment more - with JWM I presume, a very light WM. |
Re: Running Debian in a chroot
When I said "it seems faster" I only meant that it seems faster running xfce4 via Xephyr than running it via VNC. I think it's going to be slow no matter what WM you use.
|
Re: Running Debian in a chroot
JWM is easy to achieve - just apt-get install. It seems quite quick, too.
I have a question: when I call these windows managers in a Xephyr windows *as root* there's no problem in opening other applications like the console terminal. But, if I call the window manager *as user* there are dbus problems for several apps. Do you see such a behavior too? Also, when opening another window manager in a Xephyr window, I lose the ability of getting "blue" function keys like numbers, and that's quite unpractical. Unless there's a workaround, I'll stick to hildon. |
Re: Running Debian in a chroot
sylpheed works very well when you put it in vertical mode. very suitable to the tablet. xchat in debian is much better than that in maemo imo. i'll be using dillo for all of my browsing from now on methinks.
also, abiword, when you turn off real time spell checking is really very snappy. |
Re: Running Debian in a chroot
Dillo, while very fast, seems a bit on the spartan side for me. It seems to have a similar feature set to links2; good for simple web sites, but not much use for modern web application sites.
|
Re: Running Debian in a chroot
Quote:
This may be a problem with permissions. The application may have created some settings files when you were root, and then when you try running it as user, it can't read or write to the settings files. I know that's what happened with Xephyr, that's why my script has those chmod and chgrp lines in it. Also, make sure your chroot script copies the hildon /etc/group and /etc/passwd files so that your chroot "user" account is the same "user" as in hildon. Otherwise you won't be able to share tmp files between hildon and debian. Quote:
The biggest problem I have with the Xephyr WM method is that it just seems slow. |
Re: Running Debian in a chroot
Dillo is real nice; it's a shame about the developer needing to eat... It got put on the back burner, and will probably never be brought up to speed now. CSS and such were supposed to arrive right after the version which is now in perpetual alpha.
I find it (the GTK version, I haven't tried the FLTK alpha) better than links2, overall... I think it misses "proper" frames support, but frames are rarely a good idea anyway, IMHO. But of course, modern web apps are designed around modern web browsers, and no light-weight will ever be caught up on enough features to do well on them. |
Re: Running Debian in a chroot
I got all excited when summatusmentis posted an expanded icon .desktop file that included the line
Quote:
|
Re: Running Debian in a chroot
Quote:
Quote:
|
Re: Running Debian in a chroot
Quote:
FIXED: When your application complains of dbus errors, then, as root, do the following: Quote:
I think it wouldn't hurt to put those lines in the hilda and xephce4 scripts. Anyone else have any ideas? |
Re: Running Debian in a chroot
I have been able to get Gnash to display Flash videos (albeit slowly), and gappletviewer can run Java applets, but I can't seem to get a browser to run either the Gnash plugin or the java plugin.
I currently believe the best bet for a browser to do these things would be kazehakase, since it is a small, fast gecko (xulrunner) based browser that supposedly can run mozilla plugins. Epiphany-webkit doesn't do plugins, and installing konqueror means installing the whole KDE ball of wax. Here are some screenshots. The first is the Gnash standalone player running a flash video: http://farm4.static.flickr.com/3258/...6f54bb65_o.png Here is gappletviewer (found in the Debian classpath package) running this java applet, standalone: http://farm4.static.flickr.com/3127/...82f57d51_o.png |
Re: Running Debian in a chroot
That dbus chown does the trick, thanks.
Now, there is the keyboard problem, I think you have the n800 plus BT kbd so you don't see it, but with the n810 only first function chars do work, not 2nd function (blue) chars. This happens only inside a Xephyr window. Must be some specific keyboard config to be copied between the maemo root and the debian chroot. Unfortunately at present I have no clue where to look for. By the way, JWM is really cool, very minimalist and quick. Try it... |
Re: Running Debian in a chroot
Tip #1 - shorten openoffice.org startup. Fire up an openoffice instance (ex. writer), go to tools / options, then in the list look for openoffice.org and memory. Change "use for openoffice.org" to 30MB and "memory per object" to 2MB. Seems to work in my hands albeit I did no measures (placebo is enough for me :-).
Taken from http://www.linuxformat.co.uk/pdfs/do...feat_speed.pdf which is a very interesting source of speeding advices. Tip #2 - move around windows in matchbox. Very useful with debian apps windows under hildon/matchbox. See http://www.internettablettalk.com/fo...cking+matchbox - thanks to Anakin - and apply the "DIALOGMODE = free" hack. I already posted it in another, more obscure, thread, but this is relevant also in this debian chroot thread. Tip #3 - toggle maximization of debian apps windows with n810 keyboard. If you are already using keylaunch to get mouse right click, add the following line to your /etc/keylaunchrc file Code:
key=*...Pressed F6:/home/user/togglewindowstate Code:
#!/bin/sh |
Re: Running Debian in a chroot
Quote:
Code:
sudo debian synaptic There must be some fundamental difference in ooo, then. |
Re: Running Debian in a chroot
Quote:
|
Re: Running Debian in a chroot
I installed the Debian beta3 version and I've discovered that it doesn't work as smoothly with my chroot scripts. In particular, the mpd (music player daemon) is installed, and it adds the mpd user. The users from the original install are overwritten by the default OS2008 users when you copy the /etc/passwd file in the chroot script, and then apt-get complains a lot that the mpd user is missing. I guess you need to purge mpd before copying over the passwd file.
|
Re: Running Debian in a chroot
Yeah, I'm using a modified version of the script that backs up the passwd and group files...
So I'll just put them back, but I have made no effort to install packages since then; I was just more cautious. (Because I'm using it for boot as well as chroot...) |
Re: Running Debian in a chroot
Quote:
Maybe part of my compulsive apt-getting is that every time I do an Code:
apt-get update |
Re: Running Debian in a chroot
Yes, I deleted the mpd user. I thought it was some mistake of mine when I first installed the thing. Now I think that should be added to the wiki.
Concerning packages, did you have success with iceape? It crashes in my hands, but who knows... |
Re: Running Debian in a chroot
No, iceape is a no-go here too. It would have been nice, though, wouldn't it?
|
Firefox 3
Gecko based browser news: Minimo and Icehamster have Zaurus Debian ports. They install fine with "dpkg -i <package.deb>" in my Debian chroot, and they both run. I think Icehamster is better than Kazehakase. Neither of them do flash or java, however. I still think I've got something set up wrongly. I wish someone else was working on this.
The ArmEabiHowto page has two new repositories for your /etc/apt/sources.list Quote:
Put those in your /etc/apt/sources.list, run Code:
apt-get update EDIT: It looks like it uses the Gnash and Java plugins. We now have in-browser Java applets. http://farm4.static.flickr.com/3072/...9e99a465_o.png |
Re: Running Debian in a chroot
That's not FireFox; that's IceWeasel... Sheesh!
|
Re: Running Debian in a chroot
wow iceweasel 3 is pretty sweet. i'm booting into debian and after the initial slow startup this provides a very pleasant browsing experience. All the sites which I tried work well and load very quickly including google docs.
|
Re: Running Debian in a chroot
Those *sicilianazzi* from simplemachines.it is remind us that is possible to propagate a debian system with debootstrap - in the last few minutes I made an arm lenny minbase system which is only 96.9 megabytes and includes apt - then I'll populate it with openoffice.org only. Let's see how big it gets.
|
Re: Running Debian in a chroot
Mr. Bernardis, I think you (and those other guys on your active-volcano island*) might be on to something there. A minimal Debian system built with debootstrap might be just the thing for our chroot, rather than working with the necessarily-larger bootable Debian. And it might just be the best thing for a .deb install. I would suggest sid over lenny, however. The package versions seem consistently newer in sid.
* I love volcanoes. I went to visit Etna in 1992 to watch the lava crawling down the hillside. |
Re: Running Debian in a chroot
Quote:
|
Re: Running Debian in a chroot
Quote:
I'm serious. Compare the package versions for OpenOffice.org. And I just chose that one because we've been talking about it. Lenny: 1:2.4.0-5 (no package for armel) Sid: 1:2.4.0-6 EDIT: I've decided qolling actually does require a healthy dose of ignorance on the part of the qoller. EDIT2: OK, this is all obvious after reading Debian's releases page. Sid packages, by definition, will always be higher numbers, since Lenny is going to be the next stable release and the packages are all in the queue for that goal, and Sid is under active development. |
Re: Running Debian in a chroot
I was joking; the thing is, I thought that newer packages in sid was completely obvious; lenny's currently testing (not released as stable yet, but not unstable), sid's unstable... Etch, the current stable release, doesn't exist for armel, and is thus out of the question.
|
Re: Running Debian in a chroot
News from the same category as OpenOffice.org:
Evolution runs, it just doesn't run very well (kinda slow and layout is poor for tablet). But if you need that precious MS Exchange (or Novell Groupware) compatibility, then you might put up with the headaches. http://farm4.static.flickr.com/3071/...877e57b4_o.png |
Re: Running Debian in a chroot
UPDATE: Please see this post for a larger (42MB) tarball
I did four different debootstrap variants (lenny, sid, minbase lenny, minbase sid), and the minbase sid was the smallest. I tarred up each of my variants, and I've uploaded the tiny minbase sid one for you-all. It is just over 28mb. You download the tarball, make a directory (like /debian) in your big SD clone partition, and then Code:
tar xjvf debian-minsid-armel-chroot.tgz /debian Use the chroot script from the wiki to "get into" the chroot, and then you'll have to Code:
apt-get update As for installing OpenOffice.org, I found I couldn't just install the big meta-package, it gave errors about dependencies not being installed. So I had to work my way back to the openoffice.org-core package. It gave me a full page of package names to be installed, and told me that it would use 250MB on the disk! :eek: EDIT: OK, this is weird. I installed the openoffice.org-core package. It claims to be the 1:2.4.0-6 package. When I try to install anything "above" that, however, (e.g. openoffice.org-writer) it says that it needs openoffice.org-core = 1:2.4.0-6, which is not going to be installed. EDIT2: After downloading the package and doing a Code:
dpkg -i openoffice.org-writer_2.4.0-6_armel.deb EDIT3: OK this is just wacky. There's something wrong with the versioning |
Re: Running Debian in a chroot
Just over 28 MB (bzipped), eh?
Wonder if it fits in flash memory (jffs2, so some compression, but it won't be as good as bz2), for chroot... probably not that hot, really; it'd be better, if you're trying for something useful in flash, to strip down JohnX's build and obliterate ITOS. But it'd be cool, anyway. I might try this on my internal memory. |
All times are GMT. The time now is 08:15. |
vBulletin® Version 3.8.8