Wednesday, December 24, 2008

Complie Kernel

http://ubuntuforums.org/showthread.php?t=56835

1. Deactivate ATI driver

2. Reboot

3. Check current Kernel Version
Xubuntu:~$ uname -r
2.6.27-7-generic

4. Install Ubuntu kernel sources
Xubuntu:~$ sudo apt-get install linux-source
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
linux-source-2.6.27
Suggested packages:
libncurses-dev ncurses-dev kernel-package libqt3-dev
The following NEW packages will be installed:
linux-source linux-source-2.6.27
0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
Need to get 52.0MB of archives.
After this operation, 52.1MB of additional disk space will be used.
Do you want to continue [Y/n]? Y

5.
Xubuntu:~$ sudo apt-get install kernel-package libqt3-mt-dev libncurses5-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
build-essential comerr-dev dpkg-dev g++ g++-4.3 gettext intltool-debian libaudio-dev libcups2-dev libcupsys2-dev libexpat1-dev libfontconfig1-dev libfreetype6-dev libgcrypt11-dev
libgl1-mesa-dev libglu1-mesa-dev libgnutls-dev libgpg-error-dev libice-dev libjpeg62-dev libkadm55 libkrb5-dev liblcms1-dev libmail-sendmail-perl libmng-dev libpng12-dev
libpthread-stubs0 libpthread-stubs0-dev libqt3-compat-headers libqt3-headers libqt3-mt libsm-dev libstdc++6-4.3-dev libsys-hostname-long-perl libtasn1-3-dev libx11-dev libxau-dev
libxcb-xlib0-dev libxcb1-dev libxcursor-dev libxdmcp-dev libxext-dev libxfixes-dev libxft-dev libxi-dev libxinerama-dev libxmu-dev libxmu-headers libxrandr-dev libxrender-dev
libxt-dev mesa-common-dev pkg-config po-debconf qt3-dev-tools x11proto-core-dev x11proto-fixes-dev x11proto-input-dev x11proto-kb-dev x11proto-randr-dev x11proto-render-dev
x11proto-xext-dev x11proto-xinerama-dev xtrans-dev zlib1g-dev
Suggested packages:
debian-keyring g++-multilib g++-4.3-multilib gcc-4.3-doc libstdc++6-4.3-dbg cvs gettext-doc docbook-utils libdb3-dev libncurses-dev libgcrypt11-doc gnutls-doc gnutls-bin
guile-gnutls krb5-doc libqt3-mt-mysql libqt3-mt-odbc libqt3-mt-psql libqt3-i18n qt3-doc libstdc++6-4.3-doc libmail-box-perl
The following NEW packages will be installed:
build-essential comerr-dev dpkg-dev g++ g++-4.3 gettext intltool-debian kernel-package libaudio-dev libcups2-dev libcupsys2-dev libexpat1-dev libfontconfig1-dev libfreetype6-dev
libgcrypt11-dev libgl1-mesa-dev libglu1-mesa-dev libgnutls-dev libgpg-error-dev libice-dev libjpeg62-dev libkadm55 libkrb5-dev liblcms1-dev libmail-sendmail-perl libmng-dev
libncurses5-dev libpng12-dev libpthread-stubs0 libpthread-stubs0-dev libqt3-compat-headers libqt3-headers libqt3-mt libqt3-mt-dev libsm-dev libstdc++6-4.3-dev
libsys-hostname-long-perl libtasn1-3-dev libx11-dev libxau-dev libxcb-xlib0-dev libxcb1-dev libxcursor-dev libxdmcp-dev libxext-dev libxfixes-dev libxft-dev libxi-dev
libxinerama-dev libxmu-dev libxmu-headers libxrandr-dev libxrender-dev libxt-dev mesa-common-dev pkg-config po-debconf qt3-dev-tools x11proto-core-dev x11proto-fixes-dev
x11proto-input-dev x11proto-kb-dev x11proto-randr-dev x11proto-render-dev x11proto-xext-dev x11proto-xinerama-dev xtrans-dev zlib1g-dev
0 upgraded, 68 newly installed, 0 to remove and 0 not upgraded.
Need to get 23.9MB of archives.
After this operation, 83.2MB of additional disk space will be used.
Do you want to continue [Y/n]?

6.
cd /usr/src
sudo tar --bzip2 -xvf linux-source-2.6.27.tar.bz2
sudo ln -s /usr/src/linux-source-2.6.27 /usr/src/linux
cd /usr/src/linux

7.
sudo make oldconfig

8.
sudo make menuconfig
Go to "High Memory Support" -> Select "64G"

9.
sudo make-kpkg clean
sudo make-kpkg --initrd --append-to-version=-custom kernel_image kernel_headers

10.
cd /usr/src
ls
sudo dpkg -i linux-image-2.6.27.2-custom_2.6.27.2-custom-10.00.Custom_i386.deb
sudo dpkg -i linux-headers-2.6.27.2-custom_2.6.27.2-custom-10.00.Custom_i386.deb

Thursday, December 4, 2008

vnc4server

# login to the wireless network's webpage before making connection attempts #

###################################
#Install the required applications:
>sudo apt-get install vnc4server xinetd xvnc4viewer ssh

###################################
#( http://grumpymole.blogspot.com/2006/12/xubuntu-remote-desktop-with-vnc4s... )
>sudo vi /etc/gdm/gdm.conf

#In this file, in the [daemon] section, uncomment (i.e. remove the leading '#' sign)
RemoteGreeter=/usr/lib/gdm/gdmlogin

#In the [security] section, set:
AllowRemoteRoot = false

#In the [xdmcp] section, make sure to set:
Enable=true
HonorIndirect=false

###################################
#Now, to create an entry for xinetd to start each time it receives a connect request:
> sudo vi /etc/xinetd.d/Xvnc

#put the following text:

service Xvnc
{
type = UNLISTED
disable = no
socket_type = stream
protocol = tcp
wait = yes
user = root
server = /usr/bin/Xvnc
server_args = -inetd :1 -query localhost -geometry 1024x768 -depth 16 -once -fp /usr/share/fonts/X11/misc -DisconnectClients=0 -NeverShared passwordFile=/root/.vncpasswd -extension XFIXES
port = 5901
}

###################################
#Create a password for xinetd, by running
> sudo vncpasswd /root/.vncpasswd

###################################
#Restart xinetd by running:
>sudo /etc/init.d/xinetd stop
>sudo killall Xvnc
>sudo /etc/init.d/xinetd start

###################################
#enable remote login in menu ( http://ubuntuforums.org/showthread.php?t=191564 )
# system >> administration >> login Window :: remote tab
# choose "same as local" session

#Click on the "Configure XDMCP..." buton
#Uncheck "Honor indirect request"
#Click Close on both windows

###################################
#Allow xinetd to listen:
>sudo vi /etc/xinetd.conf
#comment out parameter
#only_from = localhost

###################################
#add the user session setup:
> vi ~/.vnc/xstartup

#comment out content and add the lines:
unset SESSION_MANAGER
exec startxfce4

###################################
#Reboot and open a server in a session console:
> vnc4server -geometry 800x600

#note:
# tightVNC for Windows is unstable with key holds
# * use low bandwidth mode
# * connect to session 3 on port 5901 with: 10.10.1.10:3:5901