Hier werden die Unterschiede zwischen zwei Versionen angezeigt.
Beide Seiten der vorigen Revision Vorhergehende Überarbeitung Nächste Überarbeitung | Vorhergehende Überarbeitung | ||
becki:linux:slack_setup_tips [2010-12-25 09:03] becki |
becki:linux:slack_setup_tips [2020-06-27 09:11] (aktuell) admin ↷ Links angepasst weil Seiten im Wiki verschoben wurden |
||
---|---|---|---|
Zeile 39: | Zeile 39: | ||
==== Boot == | ==== Boot == | ||
- | Since Slack 12.0 the default Kernel to select is hugesmp.s | + | UEFI systems might need some tweaking to boot: [[slack on uefi]] |
+ | |||
+ | Since Slack 12.0 the default Kernel to select is hugesmp.s (hugse.s on 14.2 64Bit) | ||
<del>Select kernel: Since Slack 10.2 I prefer ''bareacpi.i'' over the default ''bare.i'' for standard IDE Systems. For my SCSI-PC I use ''adaptec.s''. ''lspci -v'' will help to select the suitable kernel.</del> (obsolete) | <del>Select kernel: Since Slack 10.2 I prefer ''bareacpi.i'' over the default ''bare.i'' for standard IDE Systems. For my SCSI-PC I use ''adaptec.s''. ''lspci -v'' will help to select the suitable kernel.</del> (obsolete) | ||
Zeile 55: | Zeile 57: | ||
=== Swap == | === Swap == | ||
- | Imho the total of RAM and swap space should be at least 256MB as of Slack 12.0. Eg if the command ''free'' says, you have 64 MB of RAM then the swap partition should have 192 MB. | + | If you have plenty of RAM than Swap is not so important, but create a Swap partition anyway, probabliy with the //same size as the RAM//. Otherwise a fstab may not be created. |
- | If you have 256 or more MB of RAM than Swap is not so important, but create a Swap partition anyway, probabliy with the same size as the RAM. Otherwise a fstab may not be created. | + | Further reading: How big should my swap space be? See [[http://www.linux.com/news/software/applications/8208-all-about-linux-swap-space|All about Linux swap space]] |
=== / == | === / == | ||
- | This is where the packages of the distribution go. E.g. a full install of Slack 13.1 needs about 6 GB, so 8-9 GB is a good size for this partition | + | This is where the packages of the distribution go. E.g. a full install of Slack 13.37 needs about 6.5 GB, so 8-9 GB is a good size for this partition |
=== /home == | === /home == | ||
Zeile 76: | Zeile 78: | ||
If you want to reuse old partitions which contain already data, eg for /home /home/share you can specify them here, but **don't** select to format them! | If you want to reuse old partitions which contain already data, eg for /home /home/share you can specify them here, but **don't** select to format them! | ||
- | A note on network boot: It worked with the single line ''/mnt/cdrom/slackware *(ro,sync)'' in ''/etc/exports'' on the server and at the promt "What is the Slackware source directory" ''/mnt/cdrom/slackware''. Of course, the install DVD/CD has to be mountet in the cd-drive of the server before | + | <del>A note on network boot: It worked with the single line ''/mnt/cdrom/slackware *(ro,sync)'' in ''/etc/exports'' on the server and at the promt "What is the Slackware source directory" ''/mnt/cdrom/slackware''. Of course, the install DVD/CD has to be mountet in the cd-drive of the server before</del> |
+ | |||
+ | Package Series Selection Recommendations: If disc space is sparse deselect E (Emacs), F (FAQ's), K (Kernel Source), T (TeX typesetting language), TCL (Tcl/Tk/TclX scripting languages and tools) & Y (Classic text-based BSD games). But //select// KDEI (KDE i18n -- why??) (and remove unnecessary languages later) | ||
- | Package Series Selection Recommendations: If disc space is sparse deselect E (Emacs), F (FAQ's), K (Kernel Source), T (TeX typesetting language), TCL (Tcl/Tk/TclX scripting languages and tools) & Y (Classic text-based BSD games). But //select// KDEI (KDE i18n) (and remove unnecessary languages later) | + | :!: In order to track //all// local configuration changes, when the setup program asks to configure the network, switch to another console and make a cp of /mnt/etc |
=== Setup Example == | === Setup Example == | ||
Zeile 98: | Zeile 102: | ||
* Expert mode | * Expert mode | ||
* Begin | * Begin | ||
- | * <del>Optional Kernel Parameters: hdc=ide-scsi, (hdc: secondary master, see [[http://www.slackbook.org/html/installation-partitioning.html|slackbook]], [[tldp>sag/html/hard-disk.html|sag]] or ''ide_info /dev/hdX'' shows where the burner is)</del> FIXME: Still necessary with Slack12? | + | * <del>Optional Kernel Parameters: hdc=ide-scsi, (hdc: secondary master, see [[http://www.slackbook.org/html/installation-partitioning.html|slackbook]], [[tldp>sag/html/hard-disk.html|sag]] or ''ide_info /dev/hdX'' shows where the burner is)</del> |
- | * FIXME Use UTF-8 Text Console: Yes | + | * Use UTF-8 Text Console: Yes (for non-english users) |
- | * Frame Buffer: 1024x768x256 (keep default) | + | * Frame Buffer: 1024x768x64k |
+ | * Use UTF-8 Text Console: YES | ||
* Lilo target: MBR (/dev/hda) | * Lilo target: MBR (/dev/hda) | ||
* Timeout: 5s | * Timeout: 5s | ||
Zeile 106: | Zeile 111: | ||
* Install | * Install | ||
* Conifg can be changed later with ''liloconfig'' or directly by editing ''/etc/lilo.conf'' & re-installing th boot loader with the command ''lilo'' | * Conifg can be changed later with ''liloconfig'' or directly by editing ''/etc/lilo.conf'' & re-installing th boot loader with the command ''lilo'' | ||
- | * Mouse: /dev/mouse PS2 (recommended & works also for touchpads. Creates the symlink /dev/mouse -> /dev/input/mice ) | + | * Mouse: /dev/mouse: ps2 (recommended & works also for touchpads. Creates the symlink /dev/mouse -> /dev/input/mice ) |
* gpm: yes | * gpm: yes | ||
- | * Configure Network: yes (or later with ''netconfig'' | + | * Configure Network: yes (or later with ''netconfig'') |
* Hostname: ilse | * Hostname: ilse | ||
* Domainname: local | * Domainname: local | ||
Zeile 116: | Zeile 121: | ||
* Gateway: No | * Gateway: No | ||
* Nameserver: No | * Nameserver: No | ||
- | * Startup services: | + | * Startup services: Keep default or activate what you need |
- | * aktivate: rc.cups, rc.mysqld, rc.httpd | + | |
- | * deaktivate: rc.inetd | + | |
* custom screen fonts: no | * custom screen fonts: no | ||
* Hardware clock set to UTC: yes | * Hardware clock set to UTC: yes | ||
* Timezone: Europe/Berlin | * Timezone: Europe/Berlin | ||
- | * Default Window Manager: xinitrc.kde | + | * Default Window Manager: xinitrc.xfce |
* Root Password: yes | * Root Password: yes | ||
* Exit | * Exit | ||
Zeile 249: | Zeile 252: | ||
==== xorg.conf == | ==== xorg.conf == | ||
- | See [[xorg_tips#etc_x11_xorg.conf|xorg_tips->etc_x11_xorg.conf]] | + | No config necessary any more. (Otherwise see [[xorg_tips#etc_x11_xorg.conf|xorg_tips->etc_x11_xorg.conf]]) |
- | ==== Alsa Sound == | + | ==== Alsa/Pulse Sound == |
- | * # alsamixer : unmute master & pcm with m-Key; set master to ~75% and pcm to 100%; Quit with ESC | + | see [[sound#Basic setup]] and as of 14.2 set mplayer to use [[sound#select_output_driver|pulse]] as output device |
- | * alsactrl store | + | |
- | Source: /etc/rc.d/rc.alsa and Bootmessages; amarok home page has also infos about alsarc configuration | + | |
==== Harddisk Standby == | ==== Harddisk Standby == | ||
Zeile 293: | Zeile 294: | ||
==== Create and install an Initrd == | ==== Create and install an Initrd == | ||
- | To use the [[slack>slackware-13.1/CHANGES_AND_HINTS.TXT|recommended]] generic instead of the huge kernel you have to build an initrd. This section is based on [[slack>slackware-13.1/README.initrd]] | + | See [[slack_initrd]] |
- | + | ||
- | Make a copy of ''/boot'' dir to be on the save side: ''cp -a /boot /boot.org'' | + | |
- | + | ||
- | Create the initial ramdisk filesystem ''/boot/initrd.gz'' with | + | |
- | mkinitrd -c -k 2.6.33.4-smp -m ext3 -f ext3 -r /dev/sda2 | + | |
- | In this example we have an ''ext3'' root "''/''" partition on ''/dev/sda2'' (see ''ls -al /dev/root'') for a kernel of version ''2.6.33.4-smp'' (See ''uname -r''). | + | |
- | Or | + | |
- | mkinitrd -c -k 2.6.33.4-smp -m reiserfs | + | |
- | for Reiserfs, or | + | |
- | mkinitrd -c -k 2.6.33.4-smp -m ext4 -f ext4 -r /dev/sda2 | + | |
- | for ext4 on /dev/sda2 | + | |
- | + | ||
- | It is not necessary to change the symlinks in /boot :?: | + | |
- | + | ||
- | Add a new image-section at the beginning of the image sections to ''/etc/lilo.config'': | + | |
- | <code> | + | |
- | image = /boot/vmlinuz-generic-smp-2.6.33.4-smp | + | |
- | initrd = /boot/initrd.gz | + | |
- | root= /dev/sda2 | + | |
- | label = LinuxGeneric | + | |
- | read-only | + | |
- | </code> | + | |
- | + | ||
- | Run ''lilo'' and restart. | + | |
- | + | ||
- | <note important>If a new kernel is installed (e.g. by running ''slackpkg''), a new ''initrd.gz'' must be created. And if ''initrd.gz'' is modified, ''lilo'' must be started again!</note> | + | |
==== Remote Login == | ==== Remote Login == | ||
Zeile 330: | Zeile 305: | ||
X11Forwarding yes | X11Forwarding yes | ||
</code> | </code> | ||
- | Additionaly log into the server with ''ssh -X''. | + | Additionaly log into the server with ''ssh -Y''. |
==== Terminal Emulator Config Example == | ==== Terminal Emulator Config Example == | ||
Zeile 476: | Zeile 451: | ||
===== Network Time Protokol NTP == | ===== Network Time Protokol NTP == | ||
- | This is a description how to setup your computer in order to fetch the accurate time from the internet. --- 2004-11-26, 2006-12-14; | + | See [[NTP]] |
- | + | ||
- | Infos taken from: [[http://www.pool.ntp.org/use.html|How do I use pool.ntp.org?]], [[http://www.edafe.org/slackware/|Time Synchronisation with NTP]] & [[http://www.ntp.org/ntpfaq/|NTP FAQ and HOWTO]] | + | |
- | + | ||
- | ==== /etc/ntp.conf == | + | |
- | + | ||
- | Replace /etc/ntp.conf with something similar to the following example. These are the servers for Germany. Replace them with the server entries for your country. You'll find them [[http://support.ntp.org/bin/view/Servers/NTPPoolServers|here]] | + | |
- | <code bash> | + | |
- | #/etc/ntp.conf: | + | |
- | driftfile /etc/ntp/drift | + | |
- | server 0.de.pool.ntp.org | + | |
- | server 1.de.pool.ntp.org | + | |
- | server 2.de.pool.ntp.org | + | |
- | server 3.de.pool.ntp.org | + | |
- | de.pool.ntp.org | + | |
- | </code> | + | |
- | + | ||
- | <del>FIXME Test this: Do not replace ntp.conf but just add the server entries below the line ''#server pool.ntp.org''</del> | + | |
- | + | ||
- | FIXME Test this: Do not replace ntp.conf but just uncomment the line | + | |
- | #server pool.ntp.org | + | |
- | and add your appropriate sub-zone, eg: | + | |
- | server de.pool.ntp.org | + | |
- | + | ||
- | If, contrary to expectations, you have servers which do not use version 4, but the older version 3 of the NTP-protocol, add 'version 3' after the server entry, eg: ''server timesource.kaeser-net.de version 3''. [[http://www.eecis.udel.edu/~mills/ntp/html/confopt.html|More]] | + | |
- | + | ||
- | To manually adjust your computer clock from time to time, just issue the command ''ntpd -q'' from now on. Or, if you want an automated adjustment, the further steps depend on your type of internet connection: | + | |
- | + | ||
- | ==== With permanent Internet Connection == | + | |
- | + | ||
- | As of Slack 12.0 just make ''/etc/rc.d/rc.ntpd'' runnable or with older versions add the following to /etc/rc.d/rc.local: | + | |
- | <code bash> | + | |
- | # Start the NTP daemon: | + | |
- | if [ -x /usr/sbin/ntpd ]; then | + | |
- | echo "Starting NTP daemon: /usr/sbin/ntpd" | + | |
- | /usr/sbin/ntpd | + | |
- | fi | + | |
- | </code> | + | |
- | + | ||
- | :!: This script doesn't seem to work, when you have only a temporarely internet connection like modem or DSL! | + | |
- | + | ||
- | Issue the command ''ntpd'' as root for the first time, and after some time (this could take as long as half an hour!), ntpq -p should output something like: | + | |
- | + | ||
- | <code> | + | |
- | remote refid st t when poll reach delay offset jitter | + | |
- | ============================================================================== | + | |
- | +81.6.42.224 193.5.216.14 2 u 68 1024 377 158.995 51.220 50.287 | + | |
- | *217.162.232.173 130.149.17.8 2 u 191 1024 176 79.245 3.589 27.454 | + | |
- | -129.132.57.95 131.188.3.222 3 u 766 1024 377 22.302 -2.928 0.508 | + | |
- | </code> | + | |
- | + | ||
- | The IP addresses will be different, because you've been assigned random timeservers. The essential thing is that one of the lines starts with an asterisk (*), this means your computer gets the time from the internet. | + | |
- | + | ||
- | FIXME Does this work with an hardware dsl router as internet connection? | + | |
- | + | ||
- | ==== With temporary Connection (Modem) == | + | |
- | + | ||
- | Add this code to the file /etc/ppp/ip-up. Create it, if it not exists and make it runnable. | + | |
- | <code bash> | + | |
- | #!/bin/bash | + | |
- | # /etc/ppp/ip-up | + | |
- | spd=$((24*60*60)) # seconds per day ; #spd=5 # test | + | |
- | today=$(($(date +%s) / spd)) # today in days since 1970 | + | |
- | last=$(($(stat -c%Y $0) / spd)) # last setting of time in days since 1970 | + | |
- | + | ||
- | if ((today>last)); then # fetch the time once a day: | + | |
- | if ntpd -q; then | + | |
- | touch $0 # remember time setting in the modification time stamp of this file | + | |
- | logger "Time set successfully" | + | |
- | else | + | |
- | logger "ntpd error while setting time!" | + | |
- | fi | + | |
- | else | + | |
- | logger "No need to set time yet" | + | |
- | fi | + | |
- | </code> | + | |
- | :!: On my pppoe DSL connection it doesn't work! | + | |
===== Shutdown == | ===== Shutdown == | ||
Zeile 658: | Zeile 557: | ||
See [[apache httpd]] | See [[apache httpd]] | ||
- | ===== Java == | + | ===== Java Runtime == |
- | ==== Newest JDK == | + | |
- | * Download e.g. ''jdk-6u11-linux-i586.bin'' from java.sun.com (no rpm) | + | Since Slack14 Java is gone. => Download ''jdk-XXXX-linux-i586.tar.gz'' from java.sun.com (no rpm) |
- | * Installation: | + | |
<code bash> | <code bash> | ||
- | mv jdk-6u11-linux-i586.bin /usr/local/lib | + | cd /usr/local |
- | cd /usr/local/lib | + | tar -xf jdk-XXXX-linux-i586.tar.gz |
- | chmod a+x jdk-6u11-linux-i586.bin | + | rm jdk-XXXX-linux-i586.tar.gz |
- | ./jdk-6u11-linux-i586.bin | + | chown -R root:root jreXXX |
- | cd /usr/lib | + | ln -s jreXXX java |
- | mv java java.org | + | cd /etc/profile.d |
- | ln -s /usr/local/lib/jdk1.6.0_11 java | + | curl -O http://download.dlackware.com/slackware/slackware/extra/java/profile.d/jre.sh |
+ | chmod +x jre.sh | ||
</code> | </code> | ||
- | ==== Default JDK == | + | <code diff> |
- | + | --- jre.sh~ 2009-04-29 19:29:03.000000000 +0200 | |
- | Since Version 10.1 Slack comes with a JRE, but no JDK. For developing in Java, download the JDK from AnySlackwareServer/extra & install it with installpkg. A default installation has a symlink ''/usr/lib/java -> /usr/lib/jre-XXX''. Among others, the install script of the JDK changes this symlink to ''/usr/lib/java -> /usr/lib/jdk-XXX'' | + | +++ jre.sh 2012-08-19 14:41:41.712846717 +0200 |
- | + | @@ -1,4 +1,4 @@ | |
- | Check install script at ''/var/log/scripts/jdk-XXX''. Check if the java plugin of firefox still works after installation --- 2007-03-29 | + | #!/bin/sh |
- | + | -export JAVA_HOME=/usr/lib/java | |
- | Old /etc/profile.d/jre.sh & new /etc/profile.d/jdk.sh are identical and double things in $MANPATH and $PATH therfore ''chmod -x jre.sh'' or ''removepkg jre-XXX'' completely! --- 2007-04-27 | + | +export JAVA_HOME=/usr/local/java |
+ | export MANPATH="${MANPATH}:${JAVA_HOME}/man" | ||
+ | export PATH="${PATH}:${JAVA_HOME}/bin" | ||
+ | </code> | ||
+ | Note: This jre.sh works for the JDK as well. It doesn't matter if you istall the JDK or just the JRE to /usr/local | ||
==== Apache Ant == | ==== Apache Ant == | ||
- | See the [[:becki:coding:apache_ant#install|Ant page in the coding section]] | + | See the [[apache_ant#install|Ant page in the coding section]] |
==== Groovy == | ==== Groovy == | ||
- | See the [[:becki:coding:groovy#install|Groovy page in the coding section]] | + | See the [[groovy#install|Groovy page in the coding section]] |
==== Apache Tomcat == | ==== Apache Tomcat == | ||
Zeile 695: | Zeile 597: | ||
===== Samba == | ===== Samba == | ||
- | ==== Expose one shared dir == | ||
- | Tested setup on Slack 12.2. | + | See [[Samba]] |
- | First create a [[http://us5.samba.org/samba/docs/man/Samba-HOWTO-Collection/install.html#id2553100|simple Samba configuration file]] ''/etc/samba/smb.conf'': | + | ===== Setup a Mailserver == |
- | <code ini> | + | For Postfix and Dovecot see [[..:my:blog:2010:0120_mailserver_tips]] |
- | [global] | + | |
- | workgroup = testgroup | + | |
- | follow symlinks = no | + | |
- | [mytest] | + | |
- | path = /smb | + | |
- | read only = no | + | |
- | guest ok = no | + | |
- | </code> | + | |
- | Test Your Config File, create a directory for the [mytest] samba share above, start samba server and check if server responds (all as root): | + | ===== Quota == |
- | <code bash> | + | See [[Quota]] |
- | testparm /etc/samba/smb.conf # test config file | + | |
- | mkdir /smb # create samba share | + | |
- | chmod 777 /smb | + | |
- | chomd +x /etc/rc.d/rc.samba # start server | + | |
- | /etc/rc.d/rc.samba start | + | |
- | smbclient -U% -L localhost # check (just press return at password promt) | + | |
- | </code> | + | |
- | + | ||
- | Enable access for a normal user (eg "sandy"). Note that the user must already have a normal login on the machine (''adduser sandy''). | + | |
- | + | ||
- | smbpasswd -a sandy | + | |
- | + | ||
- | Check if samba share is accessable as normal user sandy on the server: | + | |
- | + | ||
- | smbclient //localhost/mytest | + | |
- | + | ||
- | Check if samba share is accessable as normal user sandy on a windows client: | + | |
- | + | ||
- | M:\>net use j: \\etb-111\mytest | + | |
- | + | ||
- | Other documentation: [[http://us5.samba.org/samba/docs/using_samba/toc.html|Using Samba, 2nd Edition]], [[http://us5.samba.org/samba/docs/man/Samba-Guide/|Samba-3 by Example]], [[http://us5.samba.org/samba/docs/man/manpages-3/|Samba man pages]] | + | |
- | + | ||
- | ==== Expose home dirs per user == | + | |
- | + | ||
- | <code ini> | + | |
- | [global] | + | |
- | workgroup = testgroup | + | |
- | follow symlinks = no | + | |
- | [user] | + | |
- | path = /home/%U | + | |
- | read only = no | + | |
- | </code> | + | |
- | + | ||
- | M:\>net use j: \\etb-111\user | + | |
- | Username: sandy | + | |
- | Password: *** | + | |
- | + | ||
- | ''%U'' was found [[http://us5.samba.org/samba/docs/man/Samba-Guide/simple.html#AccountingOffice|here]] | + | |
- | + | ||
- | ==== Set file mode creation mask == | + | |
- | + | ||
- | As default a remote Win client creates a file on the server ''744 = rwxr--r--''. The mask can be [[http://us5.samba.org/samba/docs/man/manpages-3/smb.conf.5.html#CREATEMASK|changed]] with in ''smb.conf'' to e.g. the linux default ''644 = rw-r--r--'': | + | |
- | + | ||
- | <code ini> | + | |
- | [global] | + | |
- | create mask = 0644 | + | |
- | </code> | + | |
- | + | ||
- | ===== Setup a Mailserver == | + | |
- | For Postfix and Dovecot see [[mailserver tips]] |