= Slackware64 =
64 bit version of Slackware
== Installation of Slackware64 14.0 in VirtualBox ==
Physical machine: HP EliteBook 8470p core i5
Virtual machine:
* Memory 6GB //4GB
* Disc 64 GB
* Video memory 128 MB
* Settings
* System
* Processor
* Enable PAE/NX:true
* Nr Processors: 3 #2
* Acceleration
* Enable VT-x/AMD-V: true
* Enable nested paging: true
* General
* Advanced
* Mini-Toolbar: disabled # Ctrl+F
Steps:
* Boot from DVD ISO of Slackware64
* Choose keyboard pt-latin1
* Login with root
* cfdisk
* new, primary, size 64719
* new, primary, size 4002.97
* Set sda1 as bootable
* type sda1, 83, Linux
* type sda1, 82, Linux swap
* write, yes, quit
* setup, addswap, sda2
* check bad blocks? no
* select sda1, format quick, ext4 filesystem
* Install from CD or DVD, auto, /dev/sr0
* All packages, full
* skip USB bootstick
* Simple LILO, frame buffer 1024x768x64K
* UTF-8 console? yes
* MBR LILO destination
* Mouse imps2
* Gpm? No
* Network? no
* Services, rc.fuse, rc.inetd, rc.messagebus, rc.syslog, rc.sshd
* Custom screen fonts? no
* Hardware clock set to UTC
* Timezone: Europe/Lisbon
* xinitrc.wmaker
* Root pass? yes
* Reboot
* In Virtualbox export the virtual machine as a OVA file
== Portuguese console keyboard ==
Create the file /etc/rc.d/rc.keymap:
{{{
#!/bin/sh
# Load the keyboard map. More maps are in /usr/share/kbd/keymaps.
if [ -x /usr/bin/loadkeys ]; then
/usr/bin/loadkeys pt-latin1.map
fi
}}}
== Enable login by KDM ==
Edit the file /etc/inittab and change the initlevel from 3 to 4
{{{
id:4:initdefault
}}}
Edit the file /etc/kde/kdm/Xsetup and add the line
{{{
setxkbmap pt
}}}
== Change VESA frame buffer resolution to 1280x960 ==
Edit the file /etc/lilo.conf
{{{
vga = 844
}}}
Run lilo -C /etc/lilo.conf to update LILO config on the MBR.
== xterm with Zenburn look and font size 14 ==
Create file ~/.Xresources:
{{{
xterm*foreground: rgb:F6/F3/E8
xterm*background: rgb:40/40/40
xterm*font: *-fixed-*-*-*-14-*
}}}
Reload the definitions with xrdb ~/.Xresources
== X configuration for 1280x960 ==
DontZap as true disables the Ctrl+Alt+Backspace (Hard reset X).
{{{
Section "Module"
Load "dbe" # Double buffer extension
SubSection "extmod"
Option "omit xfree86-dga" # don't initialise the DGA extension
EndSubSection
Load "type1"
Load "freetype"
Load "glx"
EndSection
Section "Files"
FontPath "/usr/share/fonts/local/"
FontPath "/usr/share/fonts/misc/"
FontPath "/usr/share/fonts/OTF/"
FontPath "/usr/share/fonts/TTF/"
FontPath "/usr/share/fonts/Type1/"
FontPath "/usr/share/fonts/CID/"
FontPath "/usr/share/fonts/Speedo/"
FontPath "/usr/share/fonts/75dpi/:unscaled"
FontPath "/usr/share/fonts/100dpi/:unscaled"
FontPath "/usr/share/fonts/75dpi/"
FontPath "/usr/share/fonts/100dpi/"
FontPath "/usr/share/fonts/cyrillic/"
EndSection
Section "ServerFlags"
EndSection
Section "InputDevice"
Identifier "Keyboard1"
Driver "kbd"
EndSection
Section "InputDevice"
Identifier "Mouse1"
Driver "mouse"
Option "Protocol" "PS/2"
Option "Device" "/dev/mouse"
EndSection
Section "Monitor"
Identifier "My Monitor"
HorizSync 31.5 - 50.0
VertRefresh 40-90
EndSection
Section "Device"
Identifier "VESA Framebuffer"
Driver "vesa"
EndSection
Section "Screen"
Identifier "Screen 1"
Device "VESA Framebuffer"
Monitor "My Monitor"
DefaultDepth 24
Subsection "Display"
Depth 8
Modes "1152x864" "1024x768" "800x600" "640x480"
EndSubsection
Subsection "Display"
Depth 16
Modes "1152x864" "1024x768" "800x600" "640x480"
EndSubsection
Subsection "Display"
Depth 24
Modes "1280x960" "1152x864" "1024x768" "800x600" "640x480"
EndSubsection
Subsection "Display"
Depth 32
Modes "1280x1024" "1152x864" "1024x768" "800x600" "640x480"
EndSubsection
EndSection
Section "ServerLayout"
Identifier "Simple Layout"
Screen "Screen 1"
InputDevice "Mouse1" "CorePointer"
InputDevice "Keyboard1" "CoreKeyboard"
EndSection
Section "ServerFlags"
Option "DontZap" "true"
EndSection
}}}
== Enable network DHCP client eth0 ==
Edit the file /etc/rc.d/rc.inet1.conf
{{{
# Config information for eth0:
IPADDR[0]=""
NETMASK[0]=""
USE_DHCP[0]="yes"
DHCP_HOSTNAME[0]=""
}}}
== VirtualBox port forward ==
* Network
* NAT
* Port forwarding
* Rule1
* TCP
* Host port 2222
* Guest port 22
== Java installation ==
* Get from Oracle jdk-6u39-linux-x64.bin
* mv jdk-6u39-linux-x64.bin /usr/java
* ./jdk-6u39-linux-x64.bin # run it
* Change /etc/profile
{{{#!highlight bash
export JAVA_HOME="/usr/java/jdk1.6.0_39"
PATH="(...):JAVA_HOME/bin"
}}}
Get also http://download.oracle.com/otn-pub/java/jdk/7u60-b19/jdk-7u60-linux-x64.tar.gz
* cp jdk-7u60-linux-x64.tar.gz /usr/java
* cd /usr/java
* tar xvzf jdk-7u60-linux-x64.tar.gz
== Tomcat installation ==
* mkdir -p /usr/local/tomcat
* wget http://mirrors.fe.up.pt/pub/apache/tomcat/tomcat-7/v7.0.54/bin/apache-tomcat-7.0.54.tar.gz
* tar xvzf apache-tomcat-7.0.54.tar.gz
* useradd tomcat
* chown tomcat * -R
* chgrp users * -R
Edit /usr/local/tomcat/conf/tomcat-users.xml
{{{#!highlight xml
}}}
Start and stop tomcat with user tomcat:
* /usr/local/tomcat/bin/startup.sh
* /usr/local/tomcat/bin/shutdown.sh
== JBoss 5.1.0 ==
* adduser jboss # pass 12345678
* cd /usr/local/
* unzip jboss-5.1.0.GA.zip #
* ln -s jboss-5.1.0.GA jboss
* cp jboss_init_redhat.sh /etc/init.d
* mv /etc/init.d/jboss_init_redhat.sh /etc/init.d/jboss
* ln -s /usr/java/jdk1.6.0_39 /usr/local/jdk
* chmod 755 /etc/init.d/jboss
* cd /usr/local/jboss
* chown jboss * -R
* chgrp users * -R
* /etc/init.d/jboss start # as root, JBoss should run in jboss user context
* /etc/init.d/jboss stop # as root, JBoss should run in jboss user context
Default runlevels (2 3 4 5):
* ln -s /etc/init.d/jboss /etc/rc2.d/S99jboss
* ln -s /etc/init.d/jboss /etc/rc2.d/K10jboss
* ln -s /etc/init.d/jboss /etc/rc3.d/S99jboss
* ln -s /etc/init.d/jboss /etc/rc3.d/K10jboss
* ln -s /etc/init.d/jboss /etc/rc4.d/S99jboss
* ln -s /etc/init.d/jboss /etc/rc4.d/K10jboss
* ln -s /etc/init.d/jboss /etc/rc5.d/S99jboss
* ln -s /etc/init.d/jboss /etc/rc5.d/K10jboss
In the file /etc/init.d/jboss change JBOSS_CONF from default to all
== Glassfish 4.0 ==
* mkdir -p /opt/appsrv
* wget http://download.java.net/glassfish/4.0/release/glassfish-4.0.zip
* unzip glassfish-4.0.zip
* cd glassfish-4.0
* chown vitor *- R
* chgrp users *- R
* nano bin/asadmin
{{{#!highlight bash
AS_INSTALL=`dirname "$0"`/../glassfish
AS_INSTALL_LIB="$AS_INSTALL/lib"
. "${AS_INSTALL}/config/asenv.conf"
AS_JAVA=/usr/java/jdk1.7.0_60
JAVA_HOME==/usr/java/jdk1.7.0_60
#Depends upon Java from ../config/asenv.conf
if [ ${AS_JAVA} ]; then
JAVA=${AS_JAVA}/bin/java
fi
exec "$JAVA" -jar "$AS_INSTALL_LIB/client/appserver-cli.jar" "$@"
}}}
* bin/asadmin start-domain # if first time set the admin pass
* Access http://localhost:4848
== Mysql ==
* chmod 755 /etc/rc.d/rc.mysqld
* mysql_install_db --user=mysql
* chown -R mysql.mysql /var/lib/mysql
* /etc/rc.d/rc.mysqld start
* mysql_secure_installation
* set root password: Y
* Remove anonymous users: Y
* Disallow root login remotely? [Y/n] Y
* Remove test database and access to it? [Y/n] Y
* Reload privilege tables now? [Y/n] Y
* mysql -p
* show databases;
* exit
== Bash settings ==
File ~/.bashrc
{{{#!highlight bash
alias ls='ls --color'
#PS1="\D{%Y-%m-%d}T\A \u@\H:\w \r\n\$"
#PS1="\e[0;33m\]\D{%Y-%m-%d}T\A\[\e[m\]\r\n\e[0;32m\]\u@\H:\w\$\[\e[m\] "
PS1="\e[0;33m\]\D{%Y-%m-%d}T\A\[\e[m\] \e[0;32m\]\u@\H:\w\r\n\$\[\e[m\] "
export PATH="/home/vitor/narwhal/bin:$PATH"
}}}
== VirtualBox guest additions ==
* Insert guest additions CD image
* mount /dev/sr0 /mnt/cdrom
* cd /mnt/cdrom
* ./VBoxLinuxAdditions.run
Avoids mouse jumping around on X.
Also when using the guest VM, press Ctrl+I to disable mouse integration, to avoid mouse jumping around.
== Apache Maven installation ==
* cd /usr/local
* wget http://archive.apache.org/dist/maven/binaries/apache-maven-3.2.1-bin.tar.gz
* tar xvzf apache-maven-3.2.1-bin.tar.gz
* ln -s apache-maven-3.2.1-bin maven
* Add /usr/local/maven/bin to PATH on /etc/profile or ~./bashrc
== Change display to 1600x900x32 ==
Run VBoxManage in the host
* VBoxManage setextradata "Slack64v14" "CustomVideoMode1" "1600x900x32"
Change /etc/lilo.conf
vga=864
Change /etc/X11/xorg.org to have "1600x900" in the several modes.
* Modes "1600x900" "1152x864" "1024x768" "800x600" "640x480"
== Netbeans 7.4 ==
[[Netbeans]]
== Squirrel ==
[[Squirrel]]
== Thunderbird ==
Move the local folder to ~/ThunderbirdMail.
== vi ==
[[vim]] Zenburn
== Emacs ==
[[Emacs]] Zenburn
== Multilib 32-bit ==
http://www.slackware.com/~alien/multilib/
As root:
* lftp -c 'open http://slackware.com/~alien/multilib/ ; mirror -c -e 14.1'
* cd 14.1
* upgradepkg --reinstall --install-new *.t?z
* upgradepkg --install-new slackware64-compat32/*-compat32/*.t?z
Reboot
== Skype installation ==
* wget http://download.skype.com/linux/skype-4.3.0.37.tar.bz2
* mkdir /usr/local/skype
* cp skype-4.3.0.37.tar.bz2 /usr/local/skype/
* cd /usr/local/skype/
* tar xvif skype-4.3.0.37.tar.bz2
* cd /usr/local/skype/skype-4.3.0.37
* mv * ../
* cd ..
* rmdir skype-4.3.0.37
* chmod 755 skype
* I agree
== Apply portuguese keyboard on connecting a keyboard ==
Sometimes a USB keyboard can disconnect and connect on it's own, and loose the settings.
Check the file to see if the settings are applied '''/var/log/Xorg.0.log'''
'''/etc/X11/xorg.conf.d/keyboard.conf'''
{{{
Section "InputClass"
Identifier "Keyboard Defaults"
MatchIsKeyboard "yes"
#MatchProduct "keyboard"
Option "XkbLayout" "pt"
EndSection
}}}
== Install the VM in a Lenovo Thinkpad L440 Core i5 ==
=== Init with runlevel 1 ===
Linux init=/bin/bash root=/dev/sda1 rw
=== Changes in display ===
Run VBoxManage in the host
* VBoxManage setextradata "Slack64v14" "CustomVideoMode1" "1366x768x32"
/etc/X11/xorg.conf
{{{
Section "Module"
Load "dbe" # Double buffer extension
SubSection "extmod"
Option "omit xfree86-dga" # don't initialise the DGA extension
EndSubSection
Load "type1"
Load "freetype"
Load "glx"
EndSection
Section "Files"
FontPath "/usr/share/fonts/local/"
FontPath "/usr/share/fonts/misc/"
FontPath "/usr/share/fonts/OTF/"
FontPath "/usr/share/fonts/TTF/"
FontPath "/usr/share/fonts/Type1/"
FontPath "/usr/share/fonts/CID/"
FontPath "/usr/share/fonts/Speedo/"
FontPath "/usr/share/fonts/75dpi/:unscaled"
FontPath "/usr/share/fonts/100dpi/:unscaled"
FontPath "/usr/share/fonts/75dpi/"
FontPath "/usr/share/fonts/100dpi/"
FontPath "/usr/share/fonts/cyrillic/"
EndSection
Section "ServerFlags"
EndSection
Section "InputDevice"
Identifier "Keyboard1"
Driver "kbd"
EndSection
Section "InputDevice"
Identifier "Mouse1"
Driver "mouse"
Option "Protocol" "PS/2"
Option "Device" "/dev/mouse"
EndSection
Section "InputClass"
Identifier "Mouse1"
MatchIsPointer "on"
Option "Emulate3Buttons" "on"
EndSection
Section "Monitor"
Identifier "My Monitor"
HorizSync 31.5 - 50.0
VertRefresh 40-90
EndSection
Section "Device"
Identifier "VESA Framebuffer"
Driver "vboxvideo"
EndSection
Section "Screen"
Identifier "Screen 1"
Device "VESA Framebuffer"
Monitor "My Monitor"
DefaultDepth 24
Subsection "Display"
Depth 8
Modes "1366x768" "1024x768" "800x600" "640x480"
EndSubsection
Subsection "Display"
Depth 16
Modes "1366x768" "1024x768" "800x600" "640x480"
EndSubsection
Subsection "Display"
Depth 24
Modes "1366x768" "1024x768" "800x600" "640x480"
EndSubsection
Subsection "Display"
Depth 32
Modes "1366x768" "1024x768" "800x600" "640x480"
EndSubsection
EndSection
Section "ServerLayout"
Identifier "Simple Layout"
Screen "Screen 1"
InputDevice "Mouse1" "CorePointer"
InputDevice "Keyboard1" "CoreKeyboard"
EndSection
Section "ServerFlags"
Option "DontZap" "true"
EndSection
}}}
=== Pidgin-sipe build ===
* cd /tmp
* wget http://slackbuilds.org/slackbuilds/14.1/network/pidgin-sipe.tar.gz
* tar xvzf pidgin-sipe.tar.gz
* cd pidgin-sipe
* wget http://downloads.sourceforge.net/sipe/pidgin-sipe-1.13.3.tar.bz2
* su
* ./pidgin-sipe.SlackBuild
* installpkg /tmp/pidgin-sipe-1.13.3-x86_64-2_SBo.tgz # [[attachment:pidgin-sipe-1.13.3-x86_64-2_SBo.tgz]]
=== Local DNS ===
* chattr -i /etc/resolv.conf
* nano /etc/resolv.conf
{{{
domain bitarus.allowed.org
nameserver 127.0.0.1
}}}
* chattr +i /etc/resolv.conf
Named/bind configuration in /etc/named.conf
{{{
options {
directory "/var/named";
// Google DNS servers
forwarders{8.8.8.8;8.8.4.4;};
};
// a caching only nameserver config
zone "." IN {
type hint;
file "caching-example/named.root";
};
zone "localhost" IN {
type master;
file "caching-example/localhost.zone";
allow-update { none; };
};
zone "0.0.127.in-addr.arpa" IN {
type master;
file "caching-example/named.local";
allow-update { none; };
};
logging {
channel my_named_channel {
file "/tmp/named.log";
// syslog info;
// Set the severity to dynamic to see all the debug messages.
severity dynamic;
print-time yes;
print-severity yes;
print-category yes;
};
category queries { my_named_channel; };
category client { my_named_channel; };
category default { default_syslog; };
};
}}}
Start/stop with /etc/rc.d/rc.bind start /etc/rc.d/rc.bind stop