Thursday, May 24, 2007

Chroot: Gentoo installation steps

mount /dev/hda8 /mnt/gentoo
mount /dev/hda7 /mnt/gentoo/boot
mount -t proc none /mnt/gentoo/proc
mount -o bind /dev /mnt/gentoo/dev
/usr/sbin/chroot /mnt/gentoo /bin/bash

source /etc/profile && env-update
export PS1="(chroot) $PS1"


###################################

rc-update add net.eth0 default

passwd

useradd -m -G users acardh
# passwd acardh

nano -w /etc/rc.conf

emerge syslog-ng
# rc-update add syslog-ng default
logrotate

emerge vixie-cron
# rc-update add vixie-cron default

emerge dhcpcd

emerge grub
vi /boot/grub/grub.conf
grub
grub> root (hd0,6) (Specify where your /boot partition resides)
grub> setup (hd0,6) (Install GRUB in the MBR)
grub> quit (Exit the GRUB shell)

emerge firefox
emerge aspell



# exit
cdimage ~# cd
cdimage ~# umount /mnt/gentoo/boot /mnt/gentoo/dev /mnt/gentoo/proc /mnt/gentoo
cdimage ~# reboot





# grub.conf generated by anaconda
#
# Note that you do not have to rerun grub after making changes to this file
# NOTICE: You have a /boot partition. This means that
# all kernel and initrd paths are relative to /boot/, eg.
# root (hd0,10)
# kernel /vmlinuz-version ro root=/dev/hda12
# initrd /initrd-version.img
#boot=/dev/hda
default=0
timeout=15
splashimage=(hd0,10)/grub/splash.xpm.gz
#hiddenmenu
title Fedora Core (2.6.18-1.2257.fc5)
root (hd0,10)
kernel /vmlinuz-2.6.18-1.2257.fc5 ro root=LABEL=/ rhgb quiet
initrd /initrd-2.6.18-1.2257.fc5.img

title=Gentoo Linux 2.6.18-r6 (genkernel)
root (hd0,6)
kernel /boot/kernel-genkernel-x86-2.6.18-gentoo-r6 root=/dev/ram0 init=/linuxrc ramdisk=8192 real_root=/dev/hda8 udev
initrd /boot/initramfs-genkernel-x86-2.6.18-gentoo-r6

#title Fedora Core (2.6.18-1.2239.fc5)
# root (hd0,10)
# kernel /vmlinuz-2.6.18-1.2239.fc5 ro root=LABEL=/ rhgb quiet
# initrd /initrd-2.6.18-1.2239.fc5.img
~

Gentoo Linux on IBM ThinkPad T60

http://gentoo-wiki.com/HARDWARE_IBM_ThinkPad_T60

http://thomasgersdorf.com/linux/index.php/Gentoo_Linux_on_IBM_ThinkPad_T60

http://www.gtishrine.com/t60.php

http://www.thinkwiki.org/wiki/Category:T60

http://buzzy.tesuji.org/thinkpad_t60p.html

Wednesday, May 23, 2007

Two packages mutually blocking each other in Gentoo

I try to update and recive error:
>=x11-proto/xproto-7.0.6 (is blocking x11-libs/libX11-1.0.1-r1)

i did uninstalled xproto but my computer had xproto-7.0.5 not xproto-7.0.6

# emerge --search xproto
* x11-proto/xproto
Latest version available: 7.0.7
Latest version installed: [ Not Installed ]
Size of files: 130 kB
Homepage: http://xorg.freedesktop.org/
Description: X.Org xproto protocol headers
License: xproto


===========
The solution
emerge -C xproto && emerge -C libX11 && emerge xproto libX11
==========

Safe make.conf in Gentoo

http://gentoo-wiki.com/Safe_Cflags
x86 - (32bytes)
Intel Core Solo/Duo

vendor_id : GenuineIntel
cpu family : 6
model : 14
model name : Genuine Intel(R) CPU TXXXX @ XXXGHz

CHOST="i686-pc-linux-gnu"
CFLAGS="-march=prescott -O2 -pipe -fomit-frame-pointer"
CXXFLAGS="${CFLAGS}"

Monday, May 21, 2007

Hide a zip file in an image

Here's how to combine your .gif and .zip.

cat somefile.zip >> somefile.gif

It turns out that this works with .jpg files as well. Just

cat somefile.zip >>somefile.jpg

to retrieve the original somefile:

unzip somefile.jpg

I will leave it to the rest of you to find out what
other image formats work this way.

Sunday, May 20, 2007

WinAmp in Linux

First you have to have Wine installed in Linux.
============
4) Winamp Installs just fine, on first load it says your missing arial.ttf, download it and stick it in /home/$yourname/.wine/drive_c/windows/fonts and your good to go, loads up, I have yet to check any plugins, but I'm in the process of starting that.

============
Friends, I just discovered how to run winamp in Ubuntu. I'm amazed it runs!

1. Winamp was already installed in my windows directory (c:\windows\program files\winamp\winamp.exe)
2. I mounted (http://www.ubuntuguide.org/#windows) the windows partition in Linux
3. Browsed down to winamp installed in windows NTFS partition
4. Double clicked on winamp.exe
5. It runs, but can't play a file as yet. This is because winamp uses the direct sound system as default sound output. click "options-->preferences" from winamp menu, and change sound output to "wave out".
6. Now press L to load your favorite mp3, and press the play button!
7. Enjoy the music!
==========

http://ubuntuforums.org/archive/index.php/t-98190.html
http://www.overclock.net/linux-unix-mac/146317-short-list-things-work-linux-via.html

Thursday, May 17, 2007

IBM (Lenovo) ThinkPad Recovery CD

(Link to original webpage)
Most IBM (now Lenovo) ThinkPad laptops no longer come with recovery cds or even operating system installation cd-roms. Replacing the cds, on the expense of ThinkPad users, is a hidden service partition that contains all the recovery images and files, and provides interactive rescue and recovery predesktop workspace, which is an operating environment specifically designed for rescue and recovery operations independent of the Windows operating system.

The problems with the ThinkPad’s service partition are that it’s easily taking out some 4 to 5 GB of precious hard disk space. Beside, since it’s residing on the harddisk itself, when the harddisk is spoilt, the recovery partition will be gone too. If you change the hard drive, the Rescue and Recovery partition will not be available on the new harddisk too, so there is no way to restore the ThinkPad to the original factory state pre-load only just as when it was manufactured.

So it’s wise to create the ThinkPad product recovery cd. To get hold on the recovery cd, there are several ways:

1. Create Rescue Media or Product Recovery CD

Go to “All Programs > ThinkVantage > Create Rescue and Recovery Media. Then select your desirable type of rescue media. To create recovery CD, check the “Create a set of Product Recovery Discs now” and then click “OK” to start the creation process.

You will need about 7 cds or 1 cd and 1 dvd for the product recovery cd. And you also need to have CDRW or DVDRW drive. An external USB driver will do the job too as alternative.

2. Order Product Recovery CD from IBM

You can get a ThinkPad product recovery cd from IBM/Lenovo. However, you may not be able to do so if you’re out of warranty, and even if you’re in-warranty, you may need to pay for the cds.

To order, contact IBM/Lenovo support centre. You can find contact number of support centre here.
Get help or contribute tips or tricks at My Digital Life Forums