Sometimes we have to migrate some tables from one host to another. And sometimes we want to migrate users as well. This is how I managed to do this..
First let's read out all users
mysql --batch --skip-column-names -e "SELECT user, host FROM user" mysql
I installed Raspbian(Debian Jessie) with Kodi on my Raspberry Pi and I use my Pi as a Meda Center. This Media Center plays music, mostly radio stations, all day long. I can easily control this media-center using the Yatse-App on my phone. The Setup is almost perfect, but just almost. Sometimes I prefer to listen to my Spotify-Playlists. At the moment there are no really good music addons for that. So I came to the idea to pair my phone via bluetooth with my Pi and use the audio output of my phone to play the Spotify-playlists.
To find out the serial number of a disk I mostly use one of the following commands:
/sbin/udevadm info --query=property --name=sdb | grep ID_SERIAL ## or hdparm -i /dev/sdb | grep SerialNo
Normally I don't use the "print"-key on my keyboard. I woud like to use it to quickly create screenshots. So I'll map the following command to my .fluxbox/keys-file:
sleep 5s && import /home/dr/Screenshots/`date +%F-%T`.jpg
After 5 seconds of idle-time this command will activate a screenshot. After the cursor changed I can select a window or a region on my screen. The screenshot will be saved with it's date and time under /home/dr/Screenshots.
I tried to create an Ubuntu-container on my Debian Jessie Server and I got the following error-message:
GNU parallel is an amazing command line tool for executing jobs in parallel using one or more machines. It has a lot of features and therefore a lot of options. Fortunately the manual page is full of examples.
Most linux-users know $OLDPWD. It's an environment variable to get the recently used directory. Sometimes it would be nice to remember more visited directories. In such cases pushd and popd would be a good choice..
Most common shells do have a directory stack. By looking in the man-page of bash I found the following description of the DIRSTACK: