23. December 2017

How to start all SAP services on openSUSE

The default installation of SAP Netweaver AS ABAP Developer Edition on openSUSE might not start all services after a reboot.

An indication of the problem: port 3300 is not open. After an attempt to connect from SAP Logon you’ll get following error:

WSAECONNREFUSED: Connection refused

When you logon to the system with SAP you may see that some of SAP processes are running, but not all of them:

root      1471  0.0  0.1 172524 10772 ?        Sl   09:01   0:00 /usr/sap/hostctrl/exe/saphostexec pf=/usr/sap/hostctrl/exe/host_profile
sapadm    1521  0.0  0.0  36892  4700 ?        Ss   09:01   0:00 /usr/lib/systemd/systemd --user
sapadm    1526  0.0  0.0  86200  1716 ?        S    09:01   0:00 (sd-pam)
sapadm    1536  0.1  0.3 348208 32260 ?        Ssl  09:01   0:00 /usr/sap/hostctrl/exe/sapstartsrv pf=/usr/sap/hostctrl/exe/host_profile -D
root      1625  0.0  0.0  25568  5316 ?        Ss   09:01   0:00 /usr/sap/hostctrl/exe/saposcol -l -w60 pf=/usr/sap/hostctrl/exe/host_profile
npladm    1889  0.2  1.1 661916 92220 ?        Ssl  09:01   0:00 /usr/sap/NPL/D00/exe/sapstartsrv pf=/usr/sap/NPL/SYS/profile/NPL_D00_georgik -D -u npladm
npladm    2069  0.0  1.1 661304 89420 ?        Ssl  09:01   0:00 /usr/sap/NPL/ASCS01/exe/sapstartsrv pf=/usr/sap/NPL/SYS/profile/NPL_ASCS01_georgik -D -u npladm

As you can see there are two system accounts running on the system: sapadm, npladm. NPL is in my case System ID. The start command should be executed under npladm identity.

Launch following command as root of the system (change npladm to you own System ID):

su -c "startsap all" -l npladm

The system will start with following messages displayed in the console:

Checking syb Database
starting database NPL ...
Log file: /sybase/NPL/startdb.log
parse level 0: identified message 'Database 'master' is now online.'
parse level 1: identified message 'Database 'tempdb' is now online.'
parse level 2: identified message 'Database 'sybsystemprocs' is now online.'
parse level 3: identified message 'Recovery complete.'
Recovery Complete
startdb completed successfully
Starting Startup Agent sapstartsrv
Instance Service on host georgik started
starting SAP Instance ASCS01
Startup-Log is written to /home/npladm/startsap_ASCS01.log
/usr/sap/NPL/ASCS01/exe/sapcontrol -prot NI_HTTP -nr 01 -function Start
Instance on host rihy started
Starting Startup Agent sapstartsrv
Instance Service on host rihy started
starting SAP Instance D00
Startup-Log is written to /home/npladm/startsap_D00.log
/usr/sap/NPL/D00/exe/sapcontrol -prot NI_HTTP -nr 00 -function Start
Instance on host georgik started

You can check whether port 3300 is open:

netstat -anp | grep 3300
tcp        0      0  *               LISTEN      20212/gwrd

You should be able logon to the SAP on openSUSE without a problem.

If you’re still not able to access the machine from remote then it’s necessary to check the firewall configuration. openSUSE has a strict firewall when using default installation.

You can change firewall configuration by the command:

yast2 firewall

24. March 2017

How to start Wireshark on openSUSE

The simple way how to start Wireshark on Linux is to type:


If you run this command as a normal user you won’t be able to capture packets. In order to dump packets, you need to execute it as root. This must be done in a specific way. If try just sudo you’ll end up with interesting errors like:

Attempt #1

$ sudo su
# wireshark
QXcbConnection: Could not connect to display 
Aborted (core dumped)

Attempt #2

$ sudo wireshark
QXcbConnection: Could not connect to display 
[1]    8836 abort      sudo wireshark

The proper way how to start Wireshark is by gtk-su:

xdg-su -c wireshark

8. March 2017

How to enable line numbers in KWrite

The text editor KWrite has support for line numbers. This feature is disabled by default. You can enable it by few clicks.

From menu Settings select Configure Editor…

Navigate to Appearance. Select Borders tab, click Show line numbers and click OK.

Here you can see KWrite with enabled line numbers:

18. February 2017

How to configure Two-Finger Scrolling in openSUSE KDE to behave the same way like Apple MacBook

Two-Finger scrolling in openSUSE – KDE has same default configuration like Windows 10 on Lenovo. This configuration came from old days when users were using only mouse to navigate on the web. When using touchpad it’s natural to expect that it would behave similarly to a tablet or Apple MacBook. Apple made the switch in the direction some time ago to make it more natural. For some reasons developers keep the old style on Linux and even on Windows. Luckily it is possible to change the configuration very easily.

Go to System Settings and click Hardware – Input Devices

Select Touchpad from left pane, Scrolling from the tabs and check option Reverse scrolling – Vertical. Then click Apply.