*

Welcome, Guest. Please login or register.

Get your own OLPC - Buy an XO laptop on eBay!
Pages: [1]
Print
Author Topic: Full openSuSE 10.2 install on OLPC  (Read 8681 times)

Full openSuSE 10.2 install on OLPC

erj
Commenter

Posts: 19


March 07, 2008, 04:57:47 PM

Install Suse 10.2 (KDE desktop) onto a 4GB or greater USB drive or SD card from another system (sda1->ext3; sda2->swap [at least 256MB]). This method will probably work for any distribution using a kernel close to what is used by the OLPC (2.6.22).  This other system can be a Windows machine since you'll be booting off the installation media.  Just be careful to ONLY target your USB device for installation.  For the kind of USB device, the faster and bigger, the better (say class 6; I used PNY Optima Pro Attache 8GB initially [slower] and SanDisk Extreme III 8GB SD [faster]).  Do not install kerry/beagle or zenworks, or remove later: the less daemons in memory, the better.  I've found that the installation of openSuSE 10.2 on the OLPC with a fast SD card is very similar in performance to a Sony Viao laptop I have with a 550Mhz AMD processor and 256MB memory with the same O/S.   A lot of the procedures listed here were found either on this site or by searching the web.

Follow instructions for installing Ubuntu on USB using a disk image http://olpcnews.com/forum/index.php?topic=1435.0, starting with the "tune2fs" command down to the "We're done!" comment.  Also copied OLPC:/ofw directory to the installed SuSE system and /etc/alsa/* to /etc/alsa.d.  If you do this from the OLPC, the commands would be something like:

cp -a /ofw /media/OLPCRoot
cp -a /etc/alsa/* /media/OLPCRoot/etc/alsa.d


The /etc/fstab file created during installation will probably contain lines for the root (/) and swap partitions that reference /dev/sda1 and /dev/sda2 respectively.  This is fine for a USB flash drive, but for an SD card, the /dev/sda1 and /dev/sda2 must be changed to /dev/mmcblk0p1 and /dev/mmcblk0p2 to match the devices defined in the OLPC kernel.  In either case, add the line (this may not be necessary, but it's done by the native O/S):

none         /ofw           promfs    defaults    0 0

and if you want to mount the OLPC nand file system add the line:

mtd0                    /nand                   jffs2   defaults,noatime 0 0

Save the changes and execute the command:

mkdir /media/OLPCRoot/nand

as root.

Latest firmware (Q2D07) is necessary on your OLPC so you don't have to hold the check game pad key to prevent the screen from freezing.  Q2D13 is needed for some SD cards (one second power up problem).

After booting the OLPC with the installed openSuSE O/S, adjust the window font sizes using:

Personal Settings: Appearance & Themes: Fonts (same fonts but size mostly 7).

Make panel icons more visible by right clicking on panel:
Configure Panel: KDE Panel: Arrangement: size->large for icons.

Install other software using external USB CD or tailor on initial install, or wait until network up and SuSE + pacman catalog initialized.

Use YaST: Network Devices: Network Card: Network Setup Method->UserController with NetWorkManager
   Next
   Add
      Device Type->Wireless
      Module Name->usb8xxx
   Next
   Setup DHCP or Static as needed and select disable firewall if desired.
   Finish

You may want to delete the detected card during installation here also, or at least make it start manually.  Use KNetworkManager aplet (right click on it) to connect to provider/access point.

Enable use of audio resources:
Use YaST: User Management: User and Group Administraion:
   Edit (primary login user)
   Details
   check audio in group
   Accept
   Finish

To install non-standard software RPMs:
Use YaST: Software: Installation Source: Configured Software Catalogs:
   Add
   HTTP
   Next
   Server Name->pacman.unixheads.com
   Directory on Server->/suse/10.2
   Next
   After catalog is downloaded, set refresh to off.

Can also point to standard SuSE catalog if no CD, USB flash or disk with installation software available.

Use YaST: Software: Software Management:
   to install things like acroread, realplay, mp3 libs, mplayer, etc.

Also install xvkbd (virtual keyboard) for use in ebook mode.

To get screen arrow buttons to be visible and act as window cursor movement keys:
Copied OLPC:/etc/udev/rules.d/96-olpc-keyboard.rules to /etc/udev/rules.d.
Copied OLPC:/usr/sbin/setolpckeys to /usr/sbin.
Personal Settings: Peripherals: Mouse: Mouse Navigation->Move Pointer with keyboard (using the numpad).  To activate changes, reboot.

To remap some of the keyboard and game pad keys:
Made Xmodmap (xmodmap -pke >Xmodmap) and edit to add definitions for 2 upper right corner keys (key codes 121 and 158), divide/multiply key (187), magnify key (186) and screen orientation key (214) to F13 -> F17 respectively.  Also remapped the square (79), circle (87), check (81) and X (89) gamepad buttons to Pointer_Button1, Pointer_Button3, Pointer_Button2 and Next.  Copied Xmodmap to .Xmodmap. Made a script called keyremap in ~/bin:

Code:
#!/bin/bash
sleep 15
xmodmap /home/{your username}/.Xmodmap

and make it executable (chmod 755).  Put a link in /home/{your username}/.kde/Autostart to this script:

ln -s /home/{your username}/bin/keyremap keyremap

Restart X to put these changes into effect (logout then login).  Now when your in ebook mode, the screen arrow buttons will move the mouse curser and the top three game pad keys will act as mouse buttons and the X game pad button will act as a page down key.

To get the keyboard volume control keys to work with Kmix:
Start Kmix and right click on the Master volume slider:
Configure Global Shortcuts: Increase Volume of Master->F12
         and Decrease Volume of Master->F11

Make applications connect to keyboard keys:
Personal Settings: Regional & Accessibility: Keyboard Shortcuts: Command Shortcuts: Internet: Web Browser: Firefox: Custom and press the upper right corner key to set this key (F14) to start Firefox when pressed (any application can be used for this and all the other keys not already mapped to something. I mapped F13->ksysgaurd, F14->firefox, F15->kcalc, F16->amroc).

Remove power monitor applet (and clipboard applet if you don't use it) from panel since the OLPC is not ACPI compatible.  Also, disabled DPMS display power settings (it doesn't work correctly anyway) by:

Personal Settings: Peripherals: Display: Power Control: Disable Standby, Suspend and Power Off.

Use YaST: System: System Services: stop and disable unneeded services like acpid, pppd, nfsd, nsd, etc.

Use YaST: Hardware: Printer to install local or network printer(s).

To get the screen brighten and dimming buttons to work:
Make scrnbriten:

Code:
#
#  Brighten the OLPC screen backlight by one unit
#
b=`cat /sys/class/backlight/dcon-bl/brightness`
if [ $b = 15 ]; then
exit
fi
b=$(($b + 1))
echo $b >/sys/class/backlight/dcon-bl/brightness

and scrndim:

Code:
#
#  Dim the OLPC screen backlight by one unit
#
b=`cat /sys/class/backlight/dcon-bl/brightness`
if [ $b = 0 ]; then
exit
fi
b=$(($b - 1))
echo $b >/sys/class/backlight/dcon-bl/brightness

scripts to brighten and dim display, make them executable (chmod 755) and put them in ~/bin.  Added these scripts to menu:
Configure Panel: Menus: Edit K Menu: System: More Programs (or any other place)
   New Item
   Name->OLPC Brighten
   Command->/home/{your username}/bin/scrnbriten
   uncheck Enable Launch Feedback
   select Current Shortcut Key (None) and press F10 (brighten) key
   OK
   Save
   New Item
   Name->OLPC Dim
   Command->/home/{your username}/bin/scrndim
   uncheck Enable Launch Feedback
   select Current Shortcut Key (None) and press F9 (dimming) key
   OK
   Save

Then inserted this line (as root):

chmod 666 /sys/class/backlight/dcon-bl/brightness

into the /etc/init.d/rc.local script.

Turned off the tap-to-click function on the mouse pad using the trick (as root) of adding:

options mousedev tap_time=0

to /etc/modprobe.d/olpc.conf.dist and rebooting.

« Last Edit: May 01, 2008, 08:28:17 PM by erj » Logged

#1 Re: Full openSuSE 10.2 install on OLPC

GoremanX
Contributor
*
Posts: 36



March 30, 2008, 12:50:50 PM

Thanks greatly for this post! I have a full opensuse 10.3 setup on my XO now, and it works flawlessly. I'd been running Ubuntu+xfce4 for the last week, but I find opensuse+kde much more useful and responsive, especially since I've been using suse since the 7.x days.

A few details which should be mentioned:

- when installing opensuse onto a USB drive, make sure to install NO boot loader

- once yast is done copying files, do NOT reboot into the installed system, bring the USB drive to the XO and copy the necessary files from there

- the files I needed (in addition to what's listed above) were:
  /boot/*
  /lib/modules/*
  /lib/firmware/*

- the battery monitor in KDE does in fact work (maybe it's a different one than in opensuse 10.2)

- some of the features of kpowersaved do work, for example the automatic screen dimming after a set amount of time, which dims the backlight. I didn't have to do anything for that to work. It also automatically detects if the power cord is plugged in or not, and events can be set for different battery levels.

all the rest was pretty much as explained in this post and the Ubuntu Compressed Files installation

Please note, I run the XO overclocked while running opensuse. 

Logged

#2 Re: Full openSuSE 10.2 install on OLPC

erj
Commenter

Posts: 19


March 31, 2008, 09:13:57 AM

Thanks for your additions.  When I started this process back in January, I wasn't taking notes because posting the results wasn't a concern.  So, in the back of my mind, when I started documenting it, was the nagging feeling that I was missing some steps.

Actually, I think I did install a boot loader on the flash drive and reboot into the installation machine.  But your instructions are safer, the first boot on the OLPC lets you configure things for that system instead of the installation machine, and the OLPC ignores the boot loader anyway.

The thing about the power may be a difference between openSuSE 10.2 and 10.3.  I've also done a full install of Fedora 7 and it does the dimming like you mentioned and it also powers the XO off completely on shutdown.  This isn't surprising since it's closer to the base O/S the XO uses.

BTW, an even easier way to install your favorite distribution, say from the one you use on your desktop, is to just copy everything from that machine's partition(s) that contain the distribution to the target flash or USB disk (assuming it will fit).  After you copy the distribution, just copy the /boot, /etc/modprobe.d, /lib/modules, /security directories from the OLPC, modify /etc/fstab, /etc/X11/xorg.conf and /boot/olpc.fth as needed and reboot from the OLPC.  Of course, you still have configuration tailoring to do for the OLPC, but this gets you started with something you're already use to.
« Last Edit: April 06, 2008, 11:25:15 AM by erj » Logged

#3 Re: Full openSuSE 10.2 install on OLPC

ashtond33
Contributor
*
Posts: 85



April 06, 2008, 09:45:33 AM

wow I am very interested on KDE's performance on such low resources. I've heard good things about compiling KDE from source.
Logged

#4 Re: Full openSuSE 10.2 install on OLPC

erj
Commenter

Posts: 19


April 06, 2008, 12:55:25 PM

The advantage of installing a full popular distribution instead of doing one feature at a time onto a minimal distribution is that most of the bells and whistles are already included from which you can choose (in the case of openSuSE, you can install things you missed during your original install by installing from the installation media, as well as well known repositories).  And if a package you want isn't included in the distribution, it's usually very easy to find on the internet already compiled and integrated into the distribution.  Not only did I install almost all of the KDE features and programs on my XO, but I also included twm and fvwm2.  So, if at any time I want a "lighter" window manager, I just log out from the current session and log back in with either of those window managers.

The use of the full featured display manager KDM also has its advantages.  For example, if you logout and get to the login window, you can select:

System -> Remote Login

to log into another computer that has been enabled to allow that.  Your XO then becomes an X-terminal window (thin client) to that other system.  I have logged into my desktop this way.

For those of you who pine for some form of Windows on the XO, I've installed Wine, and it works just fine for those applications that do work (check winehq.org for a compatibility list, and if the program your interested in isn't there, try it anyway: it may work!).  Although the openSuSE 10.2 distribution came with Wine, I installed the latest version from their site because it changes with updates weekly.

Other packages I've installed and used that may be of interest are:

OpenOffice suite
Adobe Reader 8
Amarok and Juk
Audacity
Real Player 10
Mplayer/GMplayer/Mencoder
Firefox with Real and Flash plugins
Java runtime
Twinkle
GIMP
XaoS
Kstars
CUPS
and lots and lots of games (KDE, Gnome and X).

As far as performance of the KDE environment, this will be somewhat tied to the SD/USB Flash/hard drive that you use, how aggressively you shut off daemons and tailor  the KDE environment, and whether you overclock your system.  As I said in the original post:

Quote
I've found that the installation of openSuSE 10.2 on the OLPC with a fast SD card is very similar in performance to a Sony Viao laptop I have with a 550Mhz AMD processor and 256MB memory with the same O/S.

I don't overclock my system and the performance is still acceptable to me.
« Last Edit: May 01, 2008, 08:35:17 PM by erj » Logged

#5 Re: Full openSuSE 10.2 install on OLPC

snakieee
Commenter

Posts: 13

crap... there goes another.....


April 27, 2008, 10:27:40 PM

sounds very nice im think im going to give it a try. being a linux noob do you think there would be a diffence if i used a usb converted laptop harddrive? or will i have problems and need to use a flash drive?
Logged

#6 Re: Full openSuSE 10.2 install on OLPC

erj
Commenter

Posts: 19


April 27, 2008, 10:42:01 PM

Any recognizable USB device should work just fine.  There are some models of SD flash that are reported to give the XO problems, but I have installed a full Fedora 7 distribution on an external USB hard drive and it worked as expected.
Logged

#7 Re: Full openSuSE 10.2 install on OLPC

Boletus
New

Posts: 1


June 04, 2008, 11:53:31 AM

I have installed Suse 10.3 on an SDHC card - actually copied it from a USB installation as my SD card is not recognised in the 10.3 installation, and it is mostly working fine. However, I have a couple of problems that I would appreciate some help with:

I can't get the sound to work. There is no /etc/alsa.d directory in the 10.3 distribution, so copying the files over does not have any effect.

When I shutdown, the system does not power off.

Small problems, but annoying. If I can get these fixed, I will put an image on my website for anyone to use.
Logged

#8 Re: Full openSuSE 10.2 install on OLPC

erj
Commenter

Posts: 19


June 04, 2008, 09:04:17 PM

Login as root to see if the sound works.  If it does, you need to set "audio" as one of your groups.  In the original post this is done by:

Quote
Enable use of audio resources:
Use YaST: User Management: User and Group Administraion:
   Edit (primary login user)
   Details
   check audio in group
   Accept
   Finish

If that doesn't work, let me know so we can start checking your /proc and /dev directories.

My openSuSE 10.2 system does not power off completely either on shutdown (have to hold down the power button for 5 seconds).
Logged

#9 Re: Full openSuSE 10.2 install on OLPC

erj
Commenter

Posts: 19


June 07, 2008, 11:53:30 AM

I found out why my system wasn't powering down all the way on shutdown.  Because I disabled all the power management features that weren't working anyway, when it executed the halt script, it assumed the "-p" option was not needed in the command to pass to the kernel.  When I edited this script (/etc/init.d/halt) to include the "-p" option in all cases, it works.
Logged
Pages: [1]
Print
Jump to:  

Members
Total Members: 2406
Latest: sembik
Stats
Total Posts: 31943
Total Topics: 3843
Online Today: 36
Online Ever: 238
(April 18, 2011, 09:48:50 PM)
Users Online
Users: 0
Guests: 20
Total: 20