Slackware
Performance - Bootscreens - Dualboot
v13-current x64
First time with LVM (LVM2 Website) for host based mirroring the 2x 2TB lvols. Check that
you align the partitions on 4k sectors!
LVM2 Whats New
# lvm version # pvs -o+lv_name,lv_size,lv_attr # fdisk /dev/sda && fdisk /dev/sdb Device Boot Start End Blocks Id System /dev/sda1 * 2048 104447 51200 83 Linux 50M /dev/sda2 104448 366591 131072 8e Linux 128M /dev/sda3 366592 3907029167 1953331288 8e Linux Rest - # mkfs.ext4 /dev/sda1 && mkfs.ext4 /dev/sdb1 - # pvcreate /dev/sda2 /dev/sda3 /dev/sdb2 /dev/sdb3 # vgcreate -s 32M vg00 /dev/sda3 /dev/sda2 /dev/sdb3 /dev/sdb2 - # lvcreate -L 12G -n lvol0 vg00 /dev/sda3 # lvcreate -l 59098 -n lvol1 vg00 /dev/sda3 # lvcreate -l 128 -n lvol2 vg00 /dev/sda3 - # lvconvert -m 1 --mirrorlog mirrored /dev/vg00/lvol0 /dev/sdb3 /dev/sda2 /dev/sdb2 # lvconvert -m 1 --mirrorlog mirrored /dev/vg00/lvol1 /dev/sdb3 /dev/sda2 /dev/sdb2 # lvconvert -m 1 --mirrorlog mirrored /dev/vg00/lvol2 /dev/sdb3 /dev/sda2 /dev/sdb2 # dmsetup status - # mkfs.ext4 /dev/vg00/lvol0 # mkfs.ext4 -i 65536 /dev/vg00/lvol1 # mkswap /dev/vg00/lvol2
/ - /dev/vg00/lvol0 /home - /dev/vg00/lvol1 /boot - /dev/sda1Findings - the 96MByte partition does not fit 3x 32MByte PE. Bigger next time...
Slackware needs some manual work as there is no default initrd for the LVM scan and activation during boot.
# chroot /mnt # mkinitrd -c -k $(uname -r) -m ext4 -f ext4 -r /dev/vg00/lvol0 -L # mkinitrd -c -k 2.6.38 -r /dev/vg00/lvol0 -Land fix the lilo.conf entry
image = /boot/vmlinuz
initrd = /boot/initrd.gz
root = /dev/vg00/lvol0
label = linux
read-only
enable automatic cpu-frequency policy
# vi /etc/rc.d/rc.modules CPUFREQ=onand check it with # powertop
rsync with Slackware
v13 x64
without burning a dvd-rom
# mount -o loop disk1.iso /mnt/disk
slackpkg
keep it up2date with the most current packages in the -current branch.
# vi /etc/slackpkg/mirrors choose your mirror # slackpkg update # update filelists from mirror # slackpkg install-new # slackpkg upgrade-all # slackpkg clean-system # vi /etc/slackpkg/blacklist exclude kernel, glibc and gcc because of multilib gcc gcc-g++ glibc glibc-i18n glibc-profile glibc-solibs glibc-zoneinfo # slackpkg install kernel-source-2.6.35.11
wireless knowhow
wl-module -
Tools for linux -
Broadcom Linux Driver -
wicd Tools
# lspci 06:00.0 Network controller: Broadcom Corporation BCM43224 802.11a/b/g/n (rev 01) 06:00.0 0280: 14e4:4353 (rev 01) # lshw *-network UNCLAIMED description: Network controller product: BCM43224 802.11a/b/g/n vendor: Broadcom Corporation physical id: 0 bus info: pci@0000:06:00.0 version: 01 width: 64 bits clock: 33MHz capabilities: pm msi pciexpress bus_master cap_list configuration: latency=0 resources: memory:d2000000-d2003fff # modprobe -r b44 b43 b43legacy ssbthe ssb module can not be removed because it is used by USB modules
the Broadcom source is - as all closed source development - not up to date
and needs a change in the include file src/linux/linuxver.h
#include <linux/autoconf.h> to #include <generated/autoconf.h> # make clean # make && make installthis modul has to be loaded before ssb.ko. therefore add in rc.S before rc.udev
modprobe lib80211 modprobe wland to prevent confusion with the Marvel NIC on eth0. Add additional rules to udev
/etc/udev/rules.d/70-persistent-net.rules
# PCI device 0x11ab:ox436c (sk2)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="70:xx:yy:zz:bb:cc",
ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"
# PCI device 0x14e4:0x4353 (wl)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:xx:yy:aa:bb:cc",
ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="wlan0"
if no scan is possible - perhaps the device is powered off
# iwlist wlan0 txpower
Xorg
# Xorg -configureand add in the DEVICE section
Option "DynamicClocks" "on" Option "BIOSHotkeys" "on"and add in the MONITOR section
Option "DPMS"ATI GPU Powersave - xorg.conf from log
Change X-Window keyboard layout
# cp -p /usr/share/hal/fdi/policy/10osvendor/10-keymap.fdi /etc/hal/fdi/policy/ # vi /etc/hal/fdi/policy/10-keymap.fdi <merge key = "input.xkb.layout" type = "string">ch</merge> # /etc/rc.d/rc.hald stop # /etc/rc.d/rc.hald startsmoother fonts using $HOME/.fonts.conf and $ qtconfig
add the local users to the different groups for a fully functional hal/messagebus/udev
floppy,cdrom,video,power,plugdev...such as GUI mount in XFCE
additional external montor
# xrandr VGA-0 connected (normal left inverted right x axis y axis) 1280x1024 60.0 + ... LVDS connected 1600x900+0+0 (normal left inverted right x axis y axis) 345mm x 194mm 1600x900 60.0*+ .. # xrandr --output VGA-0 --mode 1280x1024this mirrors the notebook display to the external one.
knowhow
multilib
Slackware13 is a pure x64 os - to run 32bit applications try multilib - (offline PDF)
# massconvert32.sh -i /home/src/multilib/slackware-currentor the newer (starting with 13.1)
First update gcc + libc # upgradepkg --reinstall --install-new *.t?z get the rest # massconvert32.sh -u ftp://mirror.switch.ch/pool/3/mirror/slackware/slackware-current/slackware/ # installpkg *-compat32/*.t?z
hardware decoding
# biosdecode # dmidecode
remove the "no mail" output during login
# vi /etc/profile #if [ -x /usr/bin/biff ]; then # biff y 2> /dev/null #fi
v12.2
# lspci # sdparm
No open source driver for the ATI X1250 yet - but as as surprise, the closed source
ati driver v8.4 is working - /usr/share/ati/fglrx-install.log
The swiss german keyboard needs the followed settings in xorg.conf
Option "XkbLayout" "ch"
Special keys...
Newer Versions ATI/Slackware need a bit of
tweeking
The most actual ATI Driver 9.1 is not really compatible. So stick with 8.14..
more Infos
Copy a xinitrc template from /etc/X11/xinit/xinitrc to $HOME/.xinitrc
# aticonfig --lsp
core/mem [flags]
-----------------
* 1: 248/200 MHz [low voltage]
2: 401/200 MHz [default state]
# aticonfig --set-powerstate=1 (lower the core consumption)
# aticonfig --set-powerstate=2 (normal, default state)
xorg.conf:
Option "PowerStage" "1"
If CTRL-ALT-BACKSPACE is disabled in the xorg, add
Section "ServerFlags" Option "DontZap" "False" EndSection
If you add User with adduser command, do not forget to add a default shell for this
user in /etc/passwd - otherweise the XFCE Terminal does not work.
Scoll Mouse
Option "Protocol" "auto" Option "ZAxisMapping" "4 5 6 7"
fixe the big fonts in Seamonkey by modifying the userChrome.css
menupopup > * { font-size: 8pt !important }
menubar, menubutton, menulist, menu, menuitem { font-size: 8pt !important }
#urlbar { font-size: 8pt !important }
or simple for all elements
* { font-size: 8pt !important }
- #visudo to give Mount/Umount, Halt/Reboot, Netconfig Permission (/etc/sudoers)
- fix /sbin/halt,shutdown,reboot permissions # chmod a+s
- Mozilla dpi fix
/bin/setterm -blank 45 -powersave powerdown -powerdown 60 #if [ -x /usr/bin/biff ]; then # biff y 2> /dev/null #fi
disable UID hardening in truecrypt or
add user to vboxusers in /etc/group, fix group permission in /dev/vboxdrv and set
the VirtualBox binary to root:vboxusers and ug+s
wireless knowhow
bcm4312 -
Tools for linux -
Overview -
Wifi-Radar -
wicd Tools
# lspci search the PCI bus # lspci -n search the PCI bus to get Manufacture@Product ID or # lsusb If your IDs are not recognized, try to get the latests id-table # uppate-usbids # update-pciids # ifconfig wlan0 up # tail demsg input: b43-phy0 as /devices/virtual/input/input8 firmware: requesting b43/ucode13.fw b43-phy0 ERROR: Firmware file "b43/ucode13.fw" not found b43-phy0 ERROR: You must go to http://linuxwireless.org/en/users/Drivers/b43#devicefirmware and download the latest firmware (version 4). get the newest Firmware # wget http://bu3sch.de/b43/fwcutter/b43-fwcutter-011.tar.bz2 # tar xjf b43-fwcutter-011.tar.bz2 # cd b43-fwcutter-011 # make # cd .. # export FIRMWARE_INSTALL_DIR="/lib/firmware" # wget http://mirror2.openwrt.org/sources/broadcom-wl-4.150.10.5.tar.bz2 # tar xjf broadcom-wl-4.150.10.5.tar.bz2 # cd broadcom-wl-4.150.10.5/driver # ../../b43-fwcutter-011/b43-fwcutter -w "$FIRMWARE_INSTALL_DIR" wl_apsta_mimo.o test it... # ifconfig wlan0 down # ifconfig wlan0 up # iwlist wlan0 scan # iwconfig wlan0 essid AirWire # iwconfig wlan0 key [0-9,A-F] or # iwconfig wlan0 key s:<passphrase> # iwconfig wlan0 rate 11M # iwconfig wlan0 rate 56M # iwlist scanning
Using bootchart to improve
boot time.. starting with 46sec and after some improvements down to 36sec - a new custom kernel an some more tweaks in rc.M and .xinitrc brings me down do
33sec - another generation...
22sec with an SSD
added an rc.local-delayed for low priority jobs #!/bin/sh # delayed services /usr/bin/sleep 30s # Font Cache if [ -x /usr/bin/fc-cache ]; then echo "Updating X font indexes: /usr/bin/fc-cache -f &" /usr/bin/fc-cache -f & fi # MIME DB if [ -x /usr/bin/update-mime-database -a -d /usr/share/mime ]; then echo "Updating MIME database: /usr/bin/update-mime-database /usr/share/mime &" /usr/bin/update-mime-database /usr/share/mime 1> /dev/null 2> /dev/null & fi # GTK Input if [ -x /usr/bin/gtk-query-immodules-2.0 ]; then echo "Updating gtk.immodules: gtk-query-immodules-2.0 > /etc/gtk-2.0/gtk.immodules" /usr/bin/gtk-query-immodules-2.0 > /etc/gtk-2.0/gtk.immodules 2> /dev/null fi
do more parallel work...
/etc/rc.d/rc.cups start &
sh /etc/rc.d/rc.wicd start &
/sbin/dhcpcd -d -t ${DHCP_TIMEOUT[$i]:-15} ${DHCP_OPTIONS} ${1} &
pimp ext3 not to check every 30 mount, instead do it once a month
# tun32fs -c 0 /dev/sda2 # tune2fs -c 0 /dev/sda5 # tune2fs -i 1m /dev/sda2 # tune2fs -i 1m /dev/sda5 # tune2fs -o journal_data_writeback /dev/sda2 - Change Journaling to WRITEBACK # tune2fs -l /dev/sda2 - Check actual settings
do not use reboot/halt directly - let
shutdown -r shutdown -hdo the job.
empty log files without restart the daemons or loosing the permissions given
# > syslog.log
Usefull ..
# mkdosfs -F 32 /dev/sda3
v12.1
- /etc/fstab
noatime,commit=15- /etc/inittab
Comment out the last 3 console entries
- delete /etc/X11/xorg.conf
The default file does not find my graphic-card on the HP Notebook. After deleting it - X works
GIT Repository Browser
Chipset ATI Radeon X1200 found R500 driver experimental - contact xorg-driver-ati@lists.x.org BIOS ATI Radeon Xpress 1250 for HP_TT running Xserver v1.4.0.90 5. september 2007 f you are using a distribution you should rerun its configuration tool. If there is no such tool, or if it keeps configuring your Xserver wrong you may want to try # xorgconfig, the graphical tool shipped with Xorg. You can also let the server generate a config file: as root just run X -configure. Please note: If you appear to use the correct driver and you still keep getting this message it is very likely that your chipset isnt supported (yet). In this case you may try the vesa driver or - if this doesnt work - the vga driver. However both are entirely unaccellerated.some finetuning in /etc/X11/xorg.config
Option "XkbLayout" "ch" DefaultDepth 16Tests: $ xdriinfo, $ xdpyinfo, $ glxinfo and free3d.org / mesa3d.org / and $ glxgears
# cp /usr/lib/X11/xinit/xinitrc $HOME/.xinitrc for finetuning
- Kernelupgrade fomr 2.6.24-5 to 2.6.25.3
# cp /boot/config-huge.... /usr/src/linux # cd /usr/src/linux # make oldconfig # make menuconfig # make install the new kernel- hear some music.... # amp *.mp3 or # mpg123 *.mp3
- Cups printer socket://laserjet.ahammer.ch
- Clean up installation
# pkgtool- add the local users to the different groups for a fully functional hal/messagebus/udev
floppy,cdrom,video,power,plugdev...
installing openoffice
tar xvfz OOo_Version.tar.gz cd OO..Version/ cd RPMS/ rpm2tgz *.rpm installpkg *.tgz cd desktop-integration/ Take what you need Last update: 2007-12-13 14:32/Author: Niclas Magnusson/Revision: 1.0 oder indem man die eigene JavaEngine verwendet # ./setup -j /usr/lib/java/bin/java
suspend to ram /etc/acpi/acpi_handler.sh
root@amdx2:/etc/acpi# cat acpi_handler.sh
#!/bin/sh
IFS=${IFS}/
set $@
case "$1" in
button)
case "$2" in
power) logger "Powerbutton as supsend - aha /etc/acpi/..."
/opt/powermanagement/suspend
#/sbin/init 0
;;
*) logger "ACPI action $2 is not defined"
;;
esac
;;
*)
logger "ACPI group $1 / action $2 is not defined"
;;
esac
/opt/powermanagement/suspend
#!/bin/sh
# discover video cards ID
ID=`lspci | grep VGA | awk { print $1 } | sed -e s@0000:@@ -e s@:@/@`
# securely create a temporary file
TMP_FILE=`mktemp /var/tmp/video_state.XXXXXX`
trap rm -f $TMP_FILE 0 1 15
# switch to virtual terminal 1 to avoid graphics
# corruption in X
chvt 1
# write all unwritten data (just in case)
sync
# dump current data from the video card to the
# temporary file
cat /proc/bus/pci/$ID > $TMP_FILE
# suspend
echo -n mem > /sys/power/state
# restore video card data from the temporary file
# on resume
cat $TMP_FILE > /proc/bus/pci/$ID
# switch back to virtual terminal 4 (running X)
chvt 4
# remove temporary file
rm -f $TMP_FILE
Updates /usr/share/pci.ids and /usr/share/usb.ids
# update-pciids # update-usbids
Printing
A low memory footprint solution is
LPRng in contrast to CUPS.
Compilation Fixups...
Change SHELL="/bin/bash" to SHELL=/bin/bash in Makefile $ ./configure --prefix=/opt/lprng-3.8 --disable-werror
v12
This version uses kernel v2.6 and udev on its defaults. If you port a installation - e.g. using vmware - to a different computer, your ethernet interfaces might not work. Udev checks the devices and _adds_ them to the old ones! Delete the files with the detected devices and restart. Then all ethernet interfaces will be rescaned and correctly numbered.
# cd /etc/udev/rules.d # del 75-network-devices
for some reason they changed the settings to use a dvd-based kernel to boot the system
huge.s root=/dev/hda2 rdinit= ro
ATI is not the first choice for a linux PC any more - no official open source support. So
XOrg is a bit tricky. The default configuration generates a Kernel-Panic - CAPS-Lock + Scroll-Lock are blinking :-(
Trying ALT-PrtScr-K next time - this combination should kill the all process in the current
terminal.
Xorgconfig is a textmode tool for minimal configuration - such as a VGA setting. This
should work on any PC-based system.
If this works - go on to use xorgcfg. This is an X-based tool and was able to detect
my Radeon 800 card correctly.
# xorgconfig # xorgcfg
Add some more tweaking - such as keyboard layout - you get this xorg.conf file.
Next is the sound system - OSS is nowadays completly replaced by ALSA. But ALSA does not provide any default settings. So - even if your audio device is found - no sound will be played....
# alsamixer left/right, up/down to set the volume on the channels toggle m to MUTE(MM) or activate (OO) a channel - default is MUTE ESC to quit # alsactl store creates /etc/asound.state which will be restored at boot time Teste Aufnahmefaehigkeit # arecord -f cd test.wav manuelle Konfiguration # alsaconf
MIC issue [solved]
# vi /etc/modprobe.conf options snd-hda-intel model=hpafter reboot, start alsamixer and replace with the SPACE on keyboard the red capture sign. Remove it from MIC and set it new on CAPTURE.
as floopies are a dieing race - I tried an usbstick
Stick it in and lock in the /var/log/messages file.
Jul 21 13:20:33 st11 kernel: usb 1-6: new high speed USB device using ehci_hcd and address 2 Jul 21 13:20:33 st11 kernel: usb 1-6: configuration #1 chosen from 1 choice Jul 21 13:20:33 st11 kernel: scsi4 : SCSI emulation for USB Mass Storage devices Jul 21 13:20:38 st11 kernel: scsi 4:0:0:0: Direct-Access Pretec 04GB 2.00 PQ: 0 ANSI: 2 Jul 21 13:20:38 st11 kernel: SCSI device sda: 8060927 512-byte hdwr sectors (4127 MB) Jul 21 13:20:38 st11 kernel: sda: Write Protect is off Jul 21 13:20:38 st11 kernel: SCSI device sda: 8060927 512-byte hdwr sectors (4127 MB) Jul 21 13:20:38 st11 kernel: sda: Write Protect is off Jul 21 13:20:38 st11 kernel: sda: sda1 Jul 21 13:20:38 st11 kernel: sd 4:0:0:0: Attached scsi removable disk sda Jul 21 13:20:38 st11 kernel: sd 4:0:0:0: Attached scsi generic sg0 type 0
so the usbstick is recognized and a device entry /dev/sda1 was created for usage.
Create now a mountpoint and a fstab entry such as
/dev/sda1 /mnt/usbstick auto auto,rw 0 0
and mount it # mount /mnt/usbstick
v11 - 64bit Edition
Basic installation on Games Heaven as descriped in v9.1 - format extfs3 with 2048 segments
without x-systems.
For dualboot -> Lilo will be installed on the root partition
linux: bare.i root=/dev/hda2 noinitrd ro
to get linux online and copy the loader to the windows drive...
Missing packages can be added with
# pkgtool
such as glib-x...tar.gz, glibc-2...tar.gz, ncur...tar.gz, X-Window...
v11
kernelupgrade
$ wget http://www.kernel.org/pub/linux/kernel/v2.6/linux-2.6.21.5.tar.bz2 $ cp /boot/config-ide-2.4.33.3 /usr/src/linux-2.6.21.5/.config $ cd /usr/src/linux-2.6.21.5 $ make silentoldconfig $ make menuconfig # kontrolliere die uebernommenen Settings $ make # make modules_install # cp arch/i386/boot/bzImage /boot/bzImage-2.6.21 # cp System.map /boot/System.map-2.6.21 # cp .config /boot/config-2.6.21add the new kernel to the lilo.conf in /etc and update the settings
# lilo
links
upgrading to v2.6
v9.1
install
after inserting the Slackware 9.1 CD1, an ENTER starts the installation. As replacement of a boot-diskette use this CD with the option bare.i root=/dev/hda1 noinitrd ro to boot the linux an the harddisk.
Settings:
- (Press 1 for selection) select keyboard map: qwertz/sg.map - Swiss German
- Press root for logon
- # fdisk /dev/hda - 40MByte /boot, 3GByte /, 128MByte SWAP, 50GByte /opt
- # network - ENTER autoprobe and DHCP ok
- # setup (after installation pkgtool, also installpkg and install-packages are available)
Slackware Linux Setup:
- ADDSWAP - /dev/hda5
- TARGET - format ext3 only, 2048 Byts per node - default 4096
- SOURCE - CDROM autoprobe - /dev/hdd
- SELECT - all, except Games, Tcl, TeX, KDE, KDEi, GNOME, F, E, X, XAPP, Kernelsource
- INSTALL - expert - choose packets manually -> Base system with compiler
- CONFIGURE- defaultkernel, no bootdisk, no modem, simple lilo in mbr
- no fb console, network, no custom font, timezone Europe/Zurich, root password
My developer and server machine uses only 314MByte harddisk space! Good.
Much better than the 500MByte without dev-support on a Redhat system.
system configuration
/etc/inittab
deaktivate CTRL-ALT-DELETE and console 4 - 6 using a #
/etc/lilo.conf
change console wait on boot from 1200 (120 seconds) to 100 (10 seconds) and activate the change.
# lilo.
Testing the gcc installation.
use the famous hello world
hw.c and
hw.cpp
Problems
(local mirror)?
Perhaps, the glib2-devel package is missing.
/etc/profile
mkdir $HOME/bin and add this to $PATH. Remove on the other side the . from the $PATH (last 3 lines).
Disable email notification by setting biff n
/etc/issue
Change the logon screen :-)
s -> System specification
-> Release number l -> logon terminal
/etc/rc.d/rc.M
Set the console screensaver from 15 to 45 minutes : /bin/setterm -blank 45