Notes for openSUSE
Silly little notes for myself, check out the openSUSE Wiki for serious content.
Install, upgrade, update
Release Notes
http://www.suse.com/releasenotes/i386/openSUSE/12.1/RELEASE-NOTES.en.html
Repos for 12.1
$ zypper lr -u
# | Alias | Name | Enabled | Refresh | URI
--+----------+----------+---------+---------+-------------------------------------------------------------
1 | 12.1-NON | 12.1-NON | Yes | No | http://download.opensuse.org/distribution/12.1/repo/non-oss/
2 | 12.1-OSS | 12.1-OSS | Yes | No | http://download.opensuse.org/distribution/12.1/repo/oss/
3 | 12.1-UPD | 12.1-UPD | Yes | No | http://download.opensuse.org/update/12.1/
Repos for 11.4
$ zypper lr --uri
# | Alias | Name | Enabled | Refresh | URI
--+-----------------------+-------------------------+---------+---------+----------------------------------------------------------------------------
1 | openSUSE:11.4:NonFree | openSUSE:11.4:NonFree | Yes | Yes | http://download.opensuse.org/distribution/11.4/repo/non-oss/
2 | pm-ess-11.4 | Packman-11.4 Essentials | Yes | No | http://packman.inode.at/suse/openSUSE_11.4/Essentials
3 | pm-mm-11.4 | Packman-11.4 Multimedia | Yes | No | http://packman.inode.at/suse/openSUSE_11.4/Multimedia
4 | pm-xtra-11.4 | Packman-11.4 Extra | Yes | No | http://packman.inode.at/suse/openSUSE_11.4/Extra
5 | repo-contrib-11.4 | openSUSE-11.4 Contrib | Yes | No | http://download.opensuse.org/repositories/openSUSE:/11.4:/Contrib/standard/
6 | repo-nonoss-11.4 | openSUSE-11.4 nonOSS | Yes | No | http://download.opensuse.org/distribution/11.4/repo/non-oss
7 | repo-oss-11.4 | openSUSE-11.4 OSS | Yes | No | http://download.opensuse.org/distribution/11.4/repo/oss
8 | repo-update-11.4 | openSUSE-11.4 updates | Yes | No | http://download.opensuse.org/update/11.4/
Repos for 12.1
I don't use Packman anymore, the old 'orphaned' packages are still working (basically, only mplayer and codecs), some packages were installed manually from OBS.
The Google Earth repo was configured by the official installer.
$ zypper lr -u
# | Alias | Name | Enabled | Refresh | URI
--+--------------+--------------+---------+---------+------------------------------------------------------------------------------
1 | 12.1-NON | 12.1-NON | Yes | No | http://download.opensuse.org/distribution/12.1/repo/non-oss/
2 | 12.1-OBS:Net | 12.1-OBS:Net | Yes | No | http://download.opensuse.org/repositories/network:/utilities/openSUSE_12.1/
3 | 12.1-OSS | 12.1-OSS | Yes | No | http://download.opensuse.org/distribution/12.1/repo/oss/
4 | 12.1-OSS-SRC | 12.1-OSS-SRC | Yes | No | http://download.opensuse.org/source/distribution/12.1/repo/oss/
5 | 12.1-UPD | 12.1-UPD | Yes | No | http://download.opensuse.org/update/12.1/
6 | KDE48 | KDE48 | Yes | No | http://download.opensuse.org/repositories/KDE:/Distro:/Factory/openSUSE_12.1/
7 | google-earth | google-earth | Yes | Yes | http://dl.google.com/linux/earth/rpm/stable/x86_64
Switching to systemd (as of version 11.4)
http://en.opensuse.org/Systemd#Install_systemd_on_openSUSE_Factory
# zypper in systemd systemd-sysvinit
# reboot
Installing from USB flash drive (netinstall ISO)
http://en.opensuse.org/SDB:Live_USB_stick#Install_syslinux.2Fisohybrid
In short:
# zypper in syslinux
# isohybrid /path/to/iso
# dd if=/path/to/iso of=/dev/sdX bs=1m
openSUSE version
Based on release file:
# awk '/VERSION/ {print $NF}' /etc/SuSE-release
12.1
Based on release RPM:
# rpm -q --qf "%{VERSION}\n" openSUSE-release
12.1
LSB (Linux Standard Base) distribution information (parses /etc/SuSE-release):
$ lsb_release -rs
12.1
VirtualBox binary from the official OSS repo
- The binary is VirtualBox
- You need the virtualbox-qt package
$ rpm -q --whatprovides /usr/bin/VirtualBox
virtualbox-qt-4.0.4-1.2.3.x86_64
If you want to start using VBox right after the install without rebooting, run '/etc/init.d/vboxdrv start' in order to load the module.
KDE 4.8 in openSUSE 12.1
There are several repos to choose from. See this openSUSE wiki page. I use KDE Factory (KDF):
# zypper ar -n KDE48 http://download.opensuse.org/repositories/KDE:/Distro:/Factory/openSUSE_12.1/ KDE48
# zypper ref
# zypper in --no-recommends --force-resolution --from KDE48 kdebase4-runtime kdebase4-workspace kwin konsole kdialog kate
Be aware that the above command will replace some of the Qt4 libraries, the libqt4* packages (change vendor for them).
KDialog is required for Chromium, for example.
It will NOT install KDM, Dolphin, audio layer and a dozen of other stuff, but a pretty bare KDE.
Mirrors of unsupported repositories (old versions)
ftp://ftp5.gwdg.de/pub/opensuse/discontinued/
Configuration
Disable suspend when laptop lid is closed
In file /etc/systemd/logind.conf , change the HandleLidSwitch parameter to either 'ignore' or 'lock' from the default.
#HandleLidSwitch=suspend
#HandleLidSwitch=ignore
HandleLidSwitch=lock
Setting locale to Latin instead of UTF-8
# vi /etc/sysconfig/language
RC_LANG="en_US"
Curses apps (alsamixer, mc...) in rxvt terminal
$ TERM=xterm $appname
Change boot loader theme
man gfxboot
http://en.opensuse.org/SDB:Gfxboot
Turn on ELF prelinking
# zypper in prelink
# vi /etc/sysconfig/prelink
USE_PRELINK="yes"
# SuSEconfig
Before you do this, read the related information. I guess a reboot will be necessary anyway.
prelink - An ELF Prelinking Utility (Novell)
prelink (Wikipedia)
Enable users to change "fullname" information with chfn
You may want to be able to change your name with 'chfn -f "Dummy User"'. Edit /etc/login.defs and add the letter 'f' to this line.
CHFN_RESTRICT frwh
Network settings
Configure LDAP
# vi /etc/ldap.conf
host 10.2.24.31
base ou=xxx,o=xxx,c=xxx
ldap_version 3
bind_policy soft
binddn cn=xxx,ou=xxx,ou=xxx,o=xxx,c=xxx
bindpw xxxxxxxxx
timelimit 10
bind_timelimit 5
pam_login_attribute cn
pam_password nds
nss_map_attribute uniqueMember member
pam_filter objectclass=posixAccount
nss_map_attribute uid cn
ssl start_tls
tls_checkpeer no
nss_override_attribute_value loginShell /bin/bash
The last line was necessary because the default shell was ksh from LDAP.
Related files in PAM:
/etc/pam.d/common-account
/etc/pam.d/common-auth
/etc/pam.d/common-session
/etc/pam.d/common-password
Note that pam-config will readjust the files...
There are references to LDAP resolution in /etc/nsswitch.conf:
passwd: compat
group: files ldap
hosts: files mdns4_minimal [NOTFOUND=return] dns
networks: files dns
services: files ldap
protocols: files
rpc: files
ethers: files
netmasks: files
netgroup: files ldap
publickey: files
bootparams: files
automount: files nis
aliases: files ldap
passwd_compat: ldap
Disable SUSEFirewall
Only when it is not necessary, of course! :D
# chkconfig -d SuSEfirewall2_setup
# chkconfig -d SuSEfirewall2_init
Disable IPv6
In /etc/sysctl.conf:
net.ipv6.conf.all.disable_ipv6 = 1
Configure proxy for zypper
# vi /etc/sysconfig/proxy
PROXY_ENABLED="yes"
NO_PROXY="localhost, 127.0.0.1, 10.2."
HTTP_PROXY=""
See the example lines in the file. Basically, you need to change the above.
In case you don't want anyone to be able to read proxy auth data, chmod the file - you will get a 'permission denied' for the file at each non-root login...
Static DNS configuration with DHCP
# vi /etc/sysconfig/network/config
Modify the following lines:
NETCONFIG_DNS_STATIC_SERVERS=
NETCONFIG_DNS_STATIC_SEARCHLIST=
See also the lease file(s): /var/lib/dhcpcd/dhcpcd-*.info
Other
Open LUKS encrypted volume
# cryptsetup luksOpen /dev/sdb2 ocz
Chromium: enable 'native' GTK file dialog under KDE
The problem with kdialog is that #1: it is awfully slow on huge folders (1000+ files); #2: it doesn't allow saving a file with a single Enter (you have to click on the "Save" button) while the GTK dialog is very fast and can save a file with Enter (the Save button is focused). But by default, if kdialog is not installed, you don't have a file dialog at all in Chromium under KDE.
Edit the script to which the alternatives link points to: /etc/alternatives/chromium
Insert the following lines at the variable declarations (first 10-20 lines):
unset KDE_SESSION_VERSION
unset KDE_FULL_SESSION
I found that it makes no difference whether the above link points to /usr/lib64/chromium/chromium-generic or /usr/lib64/chromium/chromium-kde.
Reference: The SVN entry in Chromium affecting the Unix file dialog behaviour
Automount requires root password in KDE4
Solution #1 Edit /usr/share/polkit-1/actions/org.freedesktop.udisks.policy - see http://michaelmk.blogspot.hu/2012/08/kde-unable-to-mount-usb-sticks.html
Solution #2 Modify ~/.xinitrc:
exec ck-launch-session startkde
See https://wiki.archlinux.org/index.php/Xinitrc
'ck-list-sessions' should show two sessions, one of them is your X11 session on $DISPLAY as 'active = TRUE'
Multimedia, graphics
Mixer problems
If the speaker doesn't work, unmute/crank up "Mono" and make sure 'pcspkr' is loaded
If you get 'Permission denied' for /dev/dsp, do:
# groupmod -A $user audio
Sound card modules are stored in /etc/modprobe.d/50-sound.conf.
Play chess
Here is a working example - I don't play chess, and even if I wanted, there are lots of online versions.
- xboard from OBS/Factory
- gnuchess as a dependency from the openSUSE repos
Using it with the GNUChess engine instead of fairymax (see the XBoard FAQ):
$ xboard -fcp "gnuchess xboard"
Festival complains about /dev/dsp
For some reason, festival tries to use OSS instead of ALSA. The error is:
Linux: can't open /dev/dsp
Put this in ~/.festivalrc:
(Parameter.set 'Audio_Command "aplay -q -c 1 -t raw -f s16 -r $SR $FILE")
(Parameter.set 'Audio_Method 'Audio_Command)
A working MPlayer from Frugalware
MPlayer is available from the Packman repos, for example:
$ zypper -q se -is MPlayer
S | Name | Type | Version | Arch | Repository
--+---------+---------+------------------------+--------+------------------------
i | MPlayer | package | 1.0rc4_r33321-1.pm.1.1 | x86_64 | Packman-11.4 Essentials
But it is broken at playing H.264:
Starting playback...
[VD_FFMPEG] Trying pixfmt=0.
Could not find matching colorspace - retrying with -vf scale...
Opening video filter: [scale]
The selected video_out device is incompatible with this codec.
Try appending the scale filter to your filter list,
e.g. -vf spp,scale instead of -vf spp.
[h264_vdpau @ 0xce0ee0]decoding to PIX_FMT_NONE is not supported.
[h264_vdpau @ 0xce0ee0]MPV_common_init() failed
[h264_vdpau @ 0xce0ee0]decode_slice_header error
[h264_vdpau @ 0xce0ee0]no frame!
Error while decoding frame!
- Download any of the the Frugalware packages
- Rename the .fpm to .tar.xz
- Extract the mplayer binary to your preferred path (make sure you adjust PATH or something if you intend to keep the openSUSE/Packman package installed)
- Install libmad0, openal-soft and libopenal1-soft (these don't come as a dependency with Packman mplayer)
- Create the following links to the current versions of the following libs. The example shows 11.4 +Packman on x86_64 vs Frugalware mplayer-1.0rc4-4-x86_64. The library versions may be different.
# ln -s /lib64/libbz2.so.1 /lib64/libbz2.so.1.0
# ln -s /usr/lib64/libx264.so.112 /usr/lib64/libx264.so.104
Enjoy your video! ;-)
I encountered the above error on Intel integrated video cards.
Getting Adobe Flash Player 64 bit beta to work under Chromium
I use the Adobe beta of the Flash plugin.
1.) If Chromium is able to find the Flash plugin in a 'standard' user-specific location from another browser, it will detect and use it. For example, ~/.mozilla/plugins/libflashplayer.so will be used by Chromium. I think you should import the other browser's configuration first.
2.) Download and extract the 64 bit Flash plugin (libflashplayer.so) from Adobe Labs and put it under /usr/lib64/chromium/plugins/ .
3.) You can still install the 'flash-player' package from the non-OSS repo, but that is usually an older version (at the time of writing, 11.4 non-OSS has 10.2.159, Adobe Labs Square is at 10.2.161)
Hardware
Android phone connected via USB
Kernel: 2.6.37.6-0.7-desktop
Phone: Samsung GT-S5830 'Galaxy Ace'
[711435.285040] usb 2-3: new high speed USB device using ehci_hcd and address 5
[711435.406269] usb 2-3: New USB device found, idVendor=04e8, idProduct=689e
[711435.406274] usb 2-3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[711435.406277] usb 2-3: Product: Samsung Android USB Device
[711435.406280] usb 2-3: Manufacturer: SAMSUNG Electronics Co., Ltd.
[711435.406282] usb 2-3: SerialNumber: S58309baxxxxx
[711435.408531] scsi6 : usb-storage 2-3:1.3
[711435.987166] cdc_acm 2-3:1.0: This device cannot do calls on its own. It is not a modem.
[711435.987274] cdc_acm 2-3:1.0: ttyACM0: USB ACM device
[711435.988372] usbcore: registered new interface driver cdc_acm
[711435.988374] cdc_acm: v0.26:USB Abstract Control Model driver for USB modems and ISDN adapters
[711436.408813] scsi 6:0:0:0: Direct-Access SAMSUNG GT-S5830 Card 0100 PQ: 0 ANSI: 2
[711436.409097] sd 6:0:0:0: Attached scsi generic sg2 type 0
[711436.413669] sd 6:0:0:0: [sdb] Attached SCSI removable disk
The internal SD card sdb doesn't show up in /proc/partitions and isn't readable with partitioning tools.
The device takes up charge through USB cable, but that's all.
Update: You must make the SD card available from the phone.
ThinkPad ACPI
This is a distro independent topic, but it applies to openSUSE as well. The ACPI functions are controlled by the thinkpad_acpi module which has a lot of options. Edit the following file if you need additional functionality (for example, fan speed or volume control):
/etc/modprobe.d/50-thinkpad_acpi.conf
For example, adding fan_control=1 will enable fan control via procfs interface.
Enable opening CD-ROM tray with the button
# echo "dev.cdrom.lock = 0" >> /etc/sysctl.conf
# sysctl -p
Desktop environments, window managers
KDE 4.6 in 11.4
Konsole: disable font smoothing
Personal settings
Application and system notifications
Manage Notifications - KDE Workspace - Login/Logout - uncheck 'Play a sound'
Launch Feedback - No Busy Cursor / 'Enable taskbar notification' Off
Desktop effects
Enable desktop effects - Off on slow hardware
Desktop search
Disable Nepomuk
Workspace behavior
Virtual desktops - Switching - configure shortcuts
Startup and shutdown
Service manager - disable unnecessary services
Session management
- uncheck 'Confirm logout'
- Default leave option: Turn off
- On Login: Start with an empty session
KDE 4.7 in 12.1
Disable Akonadi: In ~/.config/akonadi/akonadiserverrc, StartServer=False (process: 'akonadiserver')
Disable updates: Personal Settings > ... > uncheck Apper (process 'apper-sentinel')
Shutdown with poweroff: change HaltCmd from /sbin/halt to /sbin/halt -p in /usr/share/config/kdm/kdmrc
KDE 4.8 in 12.1
Common Appearance and Behavior
- Account details: Social Desktop - Enabled by default (disable); Desktop path - /home/$user/Desktop by default
- Application appearance: Fonts -> Droid Sans
- App and system notifications: Launch feedback -> No busy cursor; Disable taskbar notification
- Locale: Country, region & language -> time/date formats
- Shortcuts & gestures: Input Actions daemon -> Do not start; Input Actions settings -> disable each; Standard keyboard shortcuts -> (optional)
Workspace Appearance and Behavior
- Workspace appearance: Cursor theme -> DMZ scalable (black pointer); Window decorations -> Configure buttons (Window, Title, Minimize/maximize/close)
- Default applications: Terminal emulator; Web browser
- Workspace behaviour: Virtual desktops -> Rows = 1; Switching -> Shortcuts -> Screen edges -> maximize/tile; Workspace -> Show informational tips -> Off
Hardware
- Display and monitor: Screen saver -> Require password after -> enable (60s)
- Input devices: Keyboard settings -> layouts -> Configure (Hungarian, Shortcuts for switching: Alt-Shift); Switching policy > Application
- Power management: Dim display after... (adjust as needed); Screen energy saving (turn off) after
- Removable devices: Enable automount; uncheck options;
System Administration
- Startup and shutdown: Service Manager: disable 'Display Mgt', 'Drive Ejector', 'Nepomuk Search Module', 'Write Daemon'...; Session Management -> On Login: Start with an empty session
Other:
Classic menu
Install new themes/window decorations/icons etc
Getting Xorg to start without a desktop manager (startx, xinit)
Update 2011-11-21 - thanks to inkjetunit for pointing this out
Edit /etc/permissions.local - uncomment this line (already there)
/usr/bin/Xorg root:root 4711
Then run
# SuSEconfig --module permissions
If you do the following, the subsequent updates will reset the permissions. So don't do this. ;)
# chmod +s /usr/bin/Xorg
Disable Zeitgeist activity logging
Bear in mind that it might be needed for desktop search (I don't use it), for example, Unity requires it. See here.
# rm /etc/xdg/autostart/zeitgeist-datahub.desktop
$ rm -rf $HOME/.local/share/zeitgeist $HOME/.cache/zeitgeist
Or just uninstall the zeitgeist and zeitgeist-datahub packages:
# zypper rm zeitgeist zeitgeist-datahub
You can also shutdown Zeitgeist for a given session with:
$ zeitgeist-daemon --quit
Oracle Java Runtime Environment in 12.1
openSUSE 12.1 ships with OpenJDK and the Oracle Java is not available in the repos anymore due to a licence change.
Download the Oracle JRE for your architecture here.
The following applies to a 64-bit Linux system.
# chmod +x /path/to/jre-6u29-linux-x64-rpm.bin
# /path/to/jre-6u29-linux-x64-rpm.bin
It will install the rpm which can be managed with package managers later.
Set it to be accessible as 'java' (optional)
# update-alternatives --install /usr/bin/java java /usr/java/jre1.6.0_29/bin/java 1
# update-alternatives --list java
/usr/java/jre1.6.0_29/bin/java
/usr/lib64/jvm/jre-1.6.0-openjdk/bin/java
# update-alternatives --set java /usr/java/jre1.6.0_29/bin/java
update-alternatives: using /usr/java/jre1.6.0_29/bin/java to provide /usr/bin/java (java) in manual mode.
$ java -version
java version "1.6.0_29"
Java(TM) SE Runtime Environment (build 1.6.0_29-b11)
Java HotSpot(TM) 64-Bit Server VM (build 20.4-b02, mixed mode)
You may want to install/configure your browser plugins if you have multiple runtimes installed.
Java browser plugins
#1: Oracle Java 1.6 from Oracle
Follow the above path to install Oracle JRE which includes the plugin.
For Firefox:
cp /usr/java/jre1.6.0_29/lib/amd64/libnpjp2.so .mozilla/plugins/
Note that the above command must be executed for every user.
Alternatively, you can copy the .so file to the global plugin path of each browser (/usr/lib64/browser-plugins/) which is the recommended way.
Make sure you don't have different Java plugins in the same directory, or disable the unneeded ones!
Chrome/Chromium will find the installed plugin both under /usr/lib64 AND under .mozilla/plugins/ !
The plugin from the above RPM does NOT work in the browsers. The Java plugin does not start in Chromium at all, and it crashes Firefox.
#2: Oracle Java from the Factory repo
You can use older versions of Sun Java from the official, but outdated Factory Java repo while it is available.
To date, the following versions are available there (JRE, JDBC driver, source and plugin among others):
- 1.5 Update 22 ( java-1_5_0-sun*-1.5.0_update22-1.191*.rpm)
- 1.6 Update 26 (java-1_6_0-sun*-1.6.0.u26-61.13.*.rpm)
- 1.7 Early Access Build 104 (java-1_7_0-sun*-1.6.0.ea.b104-2.129.*.rpm)
There are separate plugin packages in this repo.
The 1.6 plugin doesn't work for me from this source either, 'Your Java is working' appears on the Java test page but the plug-in stops functioning afterwards.
#3: Oracle Java from OpenSUSE Build Service contributors
You can search for 'java-1_6_0-sun' or similar strings in the Build Service, add the repo and use packages from it, just make sure the plugin is packaged along or within the JRE.
A Hungarian man, 'hrongyorgy' maintains an Oracle Java 1.6 repo in OBS. See here.
OpenJDK and IcedTea
Just to be sure, I tried OpenJDK from the regular 12.1 OSS repo and it works both in Chromium and Firefox, tested on this online chess game. You don't have to copy the plugin because it installs to a defined Firefox plugin search path. Required packages are:
- java-1_6_0-openjdk
- icedtea-web
And of course, the java alternative must be set to /usr/lib64/jvm/java-1.6.0-openjdk-1.6.0/jre/bin/java.
If you have an Oracle Java and OpenJDK installed
Development
Query package maintainer and bug owner
=> Method 1: osc
Register with Novell
Install osc
Run osc without arguments and supply your Novell ID/password (it will be stored in plain text in $HOME/.oscrc)
You can query maintainers now.
Usage:
$ osc maintainer openSUSE:Factory bash
=> Method 2: openSUSE Build Service online search
You need to identify the repos.
Example: bash from Factory
Opinions about 12.1 ;)
<M> good lord, this distribution is going down south.
<B> dunno. for me new suse looks like unsuccessfull clone of fedora/ubuntu/dunno
<A> A: no, KDE is *broken* in 12.1, it's not a question of ease of use :-)
<A> guess I wasn't lucky with 12.1... just downgraded to 11.4... and waiting for 12.2
<h> LGee: 12.1 is really very problematic, should i use 11.4?
<n> 12.1 is serious bummer :P
<I> why the FUCK do I have to give now (in 12.1) root's password each time I try to breathe?
<o> what's wrong with 12.1?
<i> i give 12.1 - 8 out of 10 :) 8 because they keep'n adding to many GUI toys for dummies into desktop(s), KDE in particular with the akondai PIM env.
<c> i think the measure of quality for a distro is being about to install and set it up quickly and then use it without encountering issues. 12.1 does that for me.
<L> the main mistake in kdepim is this current mqseries approach <L> why the heck do we need a backend that talks to the backend which drives the backend that powers the backend which uses a backend to talk to my mail server
<C> ...: yes, a lot of things went wrong for me too when upgrading to 12.1
<w> this is the worst OS yet ... <w> ok back to 11.4
<w> why bother rushing an OS out that so messed up, they must have noticed, darn i crashed 5 times already, mulitable bugs found in 20 mins
<m> We should expect releases to fail?
< t> Thanks for the help over the past few days. I fixed my broken Suse...installed Ubuntu.