Here is a simple example on how to display date/watch with simple bash command:
$ while true; do clear; date; sleep 1; done
Filed under: Administration, Bash, Commands, Linux, Scripting | Tagged: Bash, command line, Linux | Leave a Comment »
Here is a simple example on how to display date/watch with simple bash command:
$ while true; do clear; date; sleep 1; done
Filed under: Administration, Bash, Commands, Linux, Scripting | Tagged: Bash, command line, Linux | Leave a Comment »
We all know how to list non-hidden and hidden files with ls command on shell. However I could not find out how to list only hidden files ( starting with “.” ) with only ls command. One, but not complete solution could by to using TAB key. For example ls . and pressing 2xTAB will [...]
Filed under: Commands, Linux | Tagged: command line | 1 Comment »
I always keep forgetting this bash syntax redirection. This is because of my short memory and also because I do not use it often. In many cases we need to remove a STDERR from the command output and keep only STDOUT. On the other hand there are times that we want to see STDERR and [...]
Filed under: Administration, Bash, Linux, Scripting | Tagged: bash syntax | Leave a Comment »
I have been using my current kubuntu installation for many months already and I never had a problem with my nvidia driver settings except today. From no apparent reason I have started my linux box and my default and maximum resolution was 1024×768 instead my standard 1680×1050. I have tried reinstall envy packages, doing dpkg-reconfigure [...]
Filed under: Administration, KDE, Linux | Leave a Comment »
If from some reason you need to recreate networking udev z25 rules file you would use the following cammed to achieve that:
/lib/udev/write_net_rules all_interfaces
this will recreate a z25_persistent-net.rules and include all interfaces.
Filed under: Administration, Debian, Linux | Tagged: Debian, networking, udev | Leave a Comment »
ls -R will list all files recursively. The output of such a command will produce a output containing not only a files but also full path the the each file or directory. One way to clean this output is to use grep and invert selection with -v option. Each path from ls -R command contains [...]
Filed under: Administration, Commands, Linux | Leave a Comment »
This error message took me lots of effort and time to solve it. The problem is that before storing binary data strings in the postgresql database the binary strings need to be escaped before storing them. There is on the google available subroutine for per which is doing this job. It is called escape_bytea. Anyway [...]
Filed under: Administration, Database, Debian, Perl | Tagged: binary data, encoding, error, how, Perl, postgresql, retrieve, storeage, unicode, utf8 | Leave a Comment »
Here is a very nice vim / vi text editor tutorial for beginnes as well as for more advanced users. Its very easy to follow as it has flash video attached to every section. vi editor tutorial
Filed under: Administration, Fun and Linux, Linux | Leave a Comment »
Sometimes you encounter situation when you need a perl module to support your program but perl module is not available from standard linux repositories. Installing perl module from source code is not always good idea so what would be the best is to create package for a particular module using dh-make-perl command. In my case [...]
Filed under: Administration, Debian, Linux, Perl, Ubuntu | Leave a Comment »
When documenting my server installation I needed to have a list of packages installed on my server. dpkg –get-selections is great help but it returns values/packages each on separate line including “installed” keyword. This command returns list of installed packages in the single block separated with single space:
dpkg –get-selections | awk ‘{ print $1; }’| [...]
Filed under: Administration, Commands, Debian, Linux, Ubuntu | Leave a Comment »