Archive for the 'Linux' Category

iPod mini - Linux

Thursday, August 18th, 2005

Looks like ipodlinux now supports the mini.

I’m giving this a try now.

[DRAFT]

First:
Backup the whole thing!
Step 1:
Plug iPod into my G5

Step 2:
Find the Volume
mount|grep -i ipod
/dev/disk1s3 on /Volumes/Antis iPod (local, nodev, nosuid, journaled)

So my iPod is disk1 which is the first SCSI device.

Step 3:
Backup the original OS
dd if=/dev/disk1s2 of=s2_os

Step 4:
Backup the Data

Hmmm … can’t backup /dev/disk1s3,
so we’ll backup the whole thing.
dd if=/dev/disk1 of=all
(This will take a while, so you might want to skip ahead and download all the needed stuff ;) )

Second:
Install
Step 1:
Get all the needed files:
(techzone has nightlies in the download area,
but these are for Windos only)
Get the files from ipodlinux.org
Get the latest kernel.bin.gz and podzilla.gz

Get uclinux-2.4.24-ipod2.tar.gz (or later) from SourceForge
Unpack it
tar xzf uclinux-2.4.24-ipod2.tar.gz

Get the linux filesystem from SourceForge.
Do not unpack this!

Step 2:
Get the ipodloader from SourceForge.
With the mini you need the CVS version.

cvs -d:pserver:anonymous@cvs.sourceforge.net:/cvsroot/ipodlinux login
cvs -z3 -d:pserver:anonymous@cvs.sourceforge.net:/cvsroot/ipodlinux co -P tools/ipodloader
cd tools/ipodloader

make (this assumes you have the arm-toolchain installed!)

Step 3:
Extract the Apple firmware
bin/make_fw -o apple.bin -v -e 0 Backup/s2_os

Step 4:
Create new all-in-one firmware:
bin/make_fw -3 -o apple_linux.bin -i apple.bin -l 2005-08-17-kernel.bin ipodloader-src-0.3.2/loader.bin

The resulting apple_linux.bin should be around 5MB

Step 5:
Copy the new firmware/kernel to y our iPod.
(If you skipped ahead earlier -> make sure your backup is finished!)
dd if=apple_linux.bin of=/dev/disk1s2

Step 6:
Copy the kernel libraries
cp -r lib /Volumes/Antis\ iPod

Step 7:
Extract the linux filesystem tro the iPod
tar xzf ipod_fs_040403.tar.gz -C /Volumes/Antis\ iPod/

Step 8:
Copy podzilla onto iPod and make it executable
cp 2005-08-17-podzilla /Volumes/Antis\ iPod/sbin/podzilla
chmod +x /Volumes/Antis\ iPod/sbin/podzilla

Mozilla Data URIs

Thursday, December 16th, 2004

Just in case I’ll ever have to recover a password from an old mozilla/firefox/firebird/phoenix file.

Mozilla does support data URIs.
Just strip the leading “~” and the trailing “==” from the login and password
and you have base64 encoded data.

Let Mozilla decode it:
Enter
data:;base64,WhAtEvEr
in the location bar and hit enter.

Ubuntu Linux - Welcome to Ubuntu Linux

Thursday, October 21st, 2004

I wish I had the time to start playing with another distribution:
Ubuntu Linux

feh 1.2.6 - screen lock II

Tuesday, September 21st, 2004

Just fiddled with the screen lock patch.
Now it uses the system password,
but needs to be setuid root if shadow passwords are enabled.

Would be glad if someone could do a little sanity check:

feh-1.2.6-an-screenlock.patch

G5 Mac - Gentoo

Friday, September 17th, 2004

Just booted the 2004.2 (minimal ppc64) LiveCD.
modprobe sungem; dhcpcd eth0
gave me ethernet.

About to partition the disk.
(I want/need triple boot.)
parted /dev/sda
mkpart primary 0.031 0.810
mkpart primary 0.810 2000
mkpart primary 2000 52000
mkpart primary 52000 102000
mkpart primary 102000 152627.835

This has to be wrong, but you have to start somewhere ;)

mkswap /dev/sda2
mk2efs -j /dev/sda5
mount /dev/sda5 /mnt/gentoo
cd /mnt/gentoo
wget http://dev.gentoo.org/~tgall/stage2-ppc64-20040802.tar.bz2
tar -xvjpf stage2-ppc64-20040802.tar.bz2

add -j2 to MAKEOPTS (/mnt/gentoo/etc/make.conf)
cp /etc/resolve.conf /mnt/gentoo/etc
mount -t proc none /mnt/gentoo/proc

chroot /mnt/gentoo /bin/bash
env-update
source /etc/profile

So far so good.

emerge sync
(That might take a while ;) )

New G5 Mac

Friday, September 17th, 2004

I just got a brandnew G5 Mac.

PowerMac 7,3
Dual PPC970 (with altivec)
2.5 GB RAM
160GB SATA HardDisk
GeForce FX 52000

Just about to install gentoo…

feh

Wednesday, September 1st, 2004

Tom started playing around with feh again.
[LinuxBrit] - Blog - feh work

I hope he will apply the screen lock patch (that I ‘ve sent to him yesterday) before he releases a new version.

I really like adding functionallity to tools I use every day,
but I hate to keep track of my patches ;)

Kernel 2.6.8 - Framebuffer

Monday, August 23rd, 2004

Last weekend I tried to update to 2.6.8 (from 2.6.7),
but the vesa fb driver seems to be broken.

1. I get a message about vga=834 being invalid (that should be 1400×1250@16bpp, which I have been using for quite a while now)
2. The screen totally gets scambled under the console. I can startx after booting blind and it is working, but that is very unsatisfactory.

Will stick with 2.6.7 and wait for 2.6.9 :(

trickle

Tuesday, August 17th, 2004

One of the tools I really like,
but always forget the name of when I really need it.

trickle - a lightweight userspace bandwidth shaper

’nuff said.

trickle

G5 Mac - Repartitioning

Thursday, July 15th, 2004

Got a spare 250GB harddisk.

Trying to repartition the old disk to add OSX.

Step 1:
Boot Gentoo LiveCD

Step 2:
Partition and format new (backup) disk.

Step 3:
Mount old root (->/old) and backup (-> backup).

Step 4:
Copy everything over:
cd /old; cp -ax * /backup

Step 5:
Repartition old disk.

Step 6:
Reboot (from LiveCD).

Step 7:
Format old disk.

Step 8:
Mount new root (->/new) and backup (-> backup).

Step 9:
Copy everything over:
cd /backup; cp -ax * /new

Step 12:
Bind devfs to new system.
mount -o bind /dev /new/dev

Step 11:
Chroot into the system
chroot /new

Step 12:
Mount procfs
mount -t proc none /proc

Step 13:
Do a quick check.

Step 12:
Rerun yaboot.
(Still chrooted)
ybin -v

Step 13:
Reboot (from disk) and hope for the best.

Looks like it worked :)

hacked

Wednesday, July 14th, 2004

Argl. Stupid me.

Here is what I could reconstruct:

1. I had OpenSSH 3.7 running.
2. I had iptables set up to only allow connections from certain hosts.
3. I used my DSL to connect to the internet.

4. I upgraded my kernel to 2.6.7 last week.
5. I forgot to enable the iptables module

6. Intruder used ssh exploit to gain access.

7. Intruder abused my system as an xmule/edonkey relay with a high speed connection.

I would have never noticed if not our “site security” had noticed the strange behaviour of my system.
(Loads and loads of TCP SYN)

I might get into real trouble this time :(

stoned

Tuesday, July 13th, 2004

Just wanted to say that
stoned
is not dead.

If you want one of the best curling simulations around,
go and get it.

Linux and Windows client fully working.
OSX client in the queue…

RHCA

Wednesday, June 23rd, 2004

Red Hat Certified Architect

Curriculum

I did my RHCE(ngineer) last year.
This looks like something to go for.

I really don’t use RedHat that much … well, not at all.
I’m using gentoo and debian,
but it’s always good to see what the others are up to.

And RHCE is on of the most wanted/best paid certifications by employers…

xorg under gentoo on a G5 mac

Thursday, June 17th, 2004

OK,

it’s running.

Look:

xorg on G5 Mac under gentoo

I fiddled a lot, so I’m not entirely sure what did here, but there are folks verifying it right now.

1. emerge x11-base/xorg-x11
This will run smooth, but the Xserver won’t work.
(Problem: elfloader can’t handle ppc64 relocation)

2. Convert .a and .o under /usr/X11R6/lib/modules/ to .so
ld –whole-archive -shared -o ${file%.o}.so $file
or
ld –whole-archive -shared -o ${file%.a}.so $file
Be sure to move the .o and .a away.

This will ensure dlopen is used instead of elfloader.

[snip]
#!/bin/sh

for file in *.o
do
ld –whole-archive -shared -o ${file%.o}.so $file
mv $file ${file}_BAK
done

for file in *.a
do
ld –whole-archive -shared -o ${file%.a}.so $file
mv $file ${file}_BAK
done

exit 0
[snip]

3. Link together the ATI driver with all prereqs.
We have shared objects, so there are some missing external references.
ld –whole-archive -shared -o ati_drv.so ati_drv.o radeon_drv.o atimisc_drv.o fbdev_drv.o r128_drv.o vga_drv.o ../libshadow.o ../libshadowfb.o
(Not so sure about this, since my bash-history got overwritten, keep adding until there are no unresolved externals.)

4. Grab an xorg.conf.
xorg.conf
5. Try the server.
X … still fails … trying to load vgahw_drv, which wasn’t build.

6. Tweak the ebuild:
/usr/portage/x11-base/xorg-x11/xorg-x11-6.7.0-r1.ebuild
Look for
echo “#define HaveLib64 NO” >> config/cf/host.def”
(The exact position doesn’t really matter that much…)
Add
echo “#define MakeDllModules YES” >> config/cf/host.def
echo “#define XF86VgaHw YES” >> config/cf/host.def
echo “#define XF86FBDevHw YES” >> config/cf/host.def

7. emerge x11-base/xorg-x11
This fails :(

8. Finish the Xserver build manually
cd /var/tmp/portage/xorg-x11-6.7.0-r1/work/xc/programs/Xserver/
make

9. Copy the vgahw driver
cp /var/tmp/portage/xorg-x11-6.7.0-r1/work/xc/programs/Xserver/hw/xfree86/vgahw/libvgahw.so /usr/X11R6/lib/modules/linux/

10. run X

11. be happy

12. tell the right gentoo folks, who might be able to really fix the ebuild.

13. donate $5 to unicef stating that “gentoo-ppc64 really rocks” ;)

G5 Mac - Gentoo - PPC64

Monday, June 14th, 2004

Got a G5 Mac a few hours ago.
Wiped out OSX and started to install Gentoo.

LiveCD
and
Stage2 tarball

Happily building glibc right now.

Remember use the openfirmware shell (ALT-APPLE-o-f) to boot from CD if you simply don’t manage to hit “c”-key at the right moment.
To open the CD-Drive use the “eject” button on the keyboard.

MACs are sooooo user friendly.
It’s all very intuitve … not.

RedHat - Who ate my diskspace

Wednesday, June 9th, 2004

I installed a “tiny” RedHat into VMWare yesterday.
I gave it a 4GB disk, since that would be easy to backup on a single DVD.

Today I tried to build our SDK and the disk was full.

So who is using up all the space ?
rpmsize and rpmhog are the needed helpers.


anti’s blog is proudly powered by WordPress
Entries (RSS) and Comments (RSS).