The Problem “java -version” quits with the error message “error while loading shared libraries: libjli.so: cannot open shared object file: No such file or directory” when trying to start the JVM. Case 1 The problem is there if it is run under a normal user or if it is run under the root user $ […]
Archives for February 2021
“java” command does not run the JVM that has been installed
The Problem A JDK/JRE from Oracle has been installed on a Linux machine according to the installation instructions. The “java” command does not run the JVM that has been installed. Java applications can fail to run if an unexpected Java Runtime Environment is found. Example from a Red Hat server: $ java -version java version […]
User Environment Variables With “su” and “sudo” in Linux
su and sudo allow to execute commands or shell with a different user. Depending on how they are invoked the environment variables can change, causing different command results. Both “su” and “sudo” allow to execute commands on behalf of other user. The usage of su implies the knowledge of the “other” user password except if […]
“530 Non-anonymous sessions must use encryption” – while using curl
The Problem “Non-anonymous sessions must use encryption” occurs when running curl command as root user: # curl -v -k –ftp-ssl –ftp-pasv ftp://192.168.X.X:990/ –user hcpa:XXX * About to connect() to 192.168.X.X port 990 (#0) * Trying 192.168.X.X… connected * Connected to 192.168.X.X (192.168.X.X) port 990 (#0) < 220 FTP SERVER INFOVALMER. > USER hcpa < 530 […]
Shopt: Not Found [No Such File Or Directory]
The Problem When a user logs in to the terminal using a user with the korn shell (ksh) the following messages occur: Shopt: Not Found [No Such File Or Directory] The Solution The following line was added on /etc/profile: shopt -s histappend Note: /etc/profile is a configuration file which sets the global environment for all […]
How to analyze basic system performance using – vmstat, sar, iostat and mpstat
In this post, a number of basic profiling tools that are included in most Linux systems by default will be discussed. The tools introduced in this post, vmstat, sar, iostat, and mpstat, are relatively simple but provide basic data which can be very useful when analyzing a system’s performance. For most examples we will be […]
Difference between the Java heap and native C heap
A Java process basically consists of two different heap spaces. The Java heap (new, old and perm space) And the so called native C heap. The above is often confusing when it comes to OutOfMemory errors and allocation failures. In particular in 32-bit mode where the overall process space is limited to 4gb or even […]
Ubuntu: Changing the stripe size of a striped LVM volume
Question: How can we change the stripe size of an existing logical volume? The logical volume (LV) must be converted to type RAID5 and then back to type striped to change the stripe size. An example is shown on how to change the stripe size of a logical volume with a default stripe size of […]
How to Reduce an LVM volume on Ubuntu
Question: How can I shrink an existing LVM volume to free up some space on my Ubuntu Machine? Backup existing data Before modifying any system, it is always recommended to create a backup first as there is an elevated risk of data corruption with reducing an LVM size. In most cases, the lvreduce command warns […]