Set up Steam under Debian without an installer

First of all: When setting up Steam, I act as user tester. Any other user can be used instead of tester. However, all path information in this documentation must then also be changed.

First, download the official Steam installer from their web portal. A file steam.deb is then available in the downloads folder.

If you unpack this Debian package you will find the files that are necessary under the directory /CONTENTS (unpacking with the Midnight Commander is very simple by selecting steam.deb and pressing Enter)

  • /usr/bin/steam
  • /usr/bin/steamdeps
  • /usr/lib/steam/bootstraplinux_ubuntu12_32.tar.xz

The last file can be named differently under certain circumstances. Below /usr/lib/steam (within steam.deb!) There should be only one file.

All three files are now e.g. copied to /home/tester/steam/bin (This directory must be created beforehand!) Then the following steps are carried out as user root:

sudo dpkg --add-architecture i386
sudo apt-get update
sudo apt-get install libgl1-mesa-dri:i386
sudo apt-get install libgl1-mesa-glx:i386

Now change to the directory /home/tester/steam/bin and call the file steam:

cd /home/tester/steam/bin

If packages are still missing, they are now displayed in a separate window (missing packages are installed as above, the package names displayed by Steam can be adopted 1: 1) Otherwise, the execution of the Steam application begins, which usually starts with the Update of own binaries begins. Ultimately, the usual Steam window appears where games can be started and installed.

Addendum: The way described above does not create any desktop icons and otherwise Steam is NOT integrated into the existing desktop environment via GUI but has to be started manually as stated above.

Generate spectrograms with arecord, sox and ffmpeg/avconv

Create a spectrogram (image)

The following command creates a WAV file using Alsa (Device 2.0). In this case, Sox is additionally piped, which is completely unnecessary here, however, Sox could still add various filters to the resulting test.wav change:

arecord -D hw:2,0 -r 32000 -f S16_LE -c 1 -t wav | sox -t wav -c 1 -L -b 16 -r 32000 - test.wav

Using the file test.wav that has just been created, a spectrogram is now generated:

sox test.wav -n spectrogram -o image.png

The file image.png then looks something like this (in this case a simple whistle)

Similar can also be created using avconv:

avconv -i test.avi -lavfi showspectrumpic=s=hd480:legend=0,format=yuv420p out.png

Create a spectrogram (Video)

The following instruction creates a spectrogram from a video test.avi. This is saved as a video under the name out.avi.

avconv -i test.avi -filter_complex "[0:a]showspectrum=s=854x480:mode=combined:slide=scroll:saturation=0.2:scale=log,format=yuv420p[v]" -map "[v]" -map 0:a -b:v 700k -b:a 360k out.mp4

Instead of avconvffmpeg could also have been used. The Debian version does not currently support all parameters here.


A spectrogram of a video can also be created with mplayer or with the mplayer/sox combination.

First a WAV file is created using MPlayer:

mplayer test.mp4 -ao pcm:file=/dev/stdout -vo null > test.wav

This is followed by the creation of the spectrogram:

sox test.wav -n spectrogram -o test.png

The graphics created in this way can be compared directly. With some (apparently identical) WAV files this can be difficult.

For this reason, the display of a spectrogram diff is recommended.

First a WAV diff is created:

sox -m -v 1 source1.wav -v -1 source2.wav diff.wav

Then the spectrogram diff is created:

sox diff.wav -n spectrogram -o diff.png

Transferring files with Netcat/nc

Individual files can also be transferred using netcat. To do this, the following instructions must be used on the transmitter and receiver:

On the receiver:

nc -l -p 8888 -w 5 > ziel < /dev/null

At the sender:

nc servername 8888 < quelle

Explanation: The recipient starts a server service based on the first parts, which reacts to requests on TCP port 8888. With the instruction > ziel the content of received data is written to a file name ziel.

The file transfer is started on the transmitter by entering the second instruction. Here a connection with the server servername via port 8888 is initiated and the file quelle is transferred.

The file is transmitted unencrypted and uncompressed. Using tools like gzip and openssl this could be implemented transparently.

Convert images to a single video

There are several approaches here. The order of the images is problematic. The easiest way would be by:

cat *.jpg | ffmpeg -f image2pipe -r 25 -vcodec mjpeg -i - test.mp4

A warning is issued here because the pipe is aborted and ffmpeg does not seem to be able to recognize this.

Another method would be via image names which contain a sequential counter in the file name. If this is not the case, the file names can be changed as follows:


for i in *.jpg; do
        NEW_FILENAME=$(printf "%04d.jpg" "$COUNTER")
        mv -i -- "$i" "$NEW_FILENAME"
        let COUNTER=COUNTER+1

The video can be created using:

ffmpeg -start_number 1 -i %04d.jpg -vcodec mpeg4 test.avi

In this case, the 4 fixed numerical digits on the left are filled in with 0. If the number is higher, the mask %04d must be changed accordingly.

Download YouTube videos in high quality using youtube-dl

This works with the command youtube-dl. The quality is indicated by 137+140137+140 means full HD quality (1080p)


while [ 1 ]; do
	for FILE in $(ls queue); do
		echo $FILE
		UUID=$(cat /proc/sys/kernel/random/uuid)
		mv queue/$FILE processed/$UUID
		for URL in $(cat processed/$UUID); do
			echo $URL
			youtube-dl -f 137+140 "$URL"
	echo "Warte"
	sleep 15

To get a list of all possible formats for a video, instead of the parameter -f just write -F (stand-alone, without format specification!)

youtube-dl can also download entire playlists from Youtube! If you want to start from a certain position, the parameter --playlist-start can be used.

Browse SMB/CIFS shares under Linux with smbclient

As an admin, one often wants to find out whether CIFS shares can be addressed under Linux or whether these have been created correctly in terms of authorization.

The Linux program smbclient is suitable for this purpose. It works on a console basis and thus checks can be carried out here, e.g. by scripts.

A list of possible releases of a host is requested using the following command:

smbclient -L -U admin

An output, in this case on the host mm with the user mm, looks something like this:

aw@mm:~$ smbclient -L mm -U mm
WARNING: The "syslog" option is deprecated
Enter mm's password:
Domain=[WORKGROUP] OS=[Windows 6.1] Server=[Samba 4.5.16-Debian]

        Sharename       Type      Comment
        ---------       ----      -------
        storage         Disk      Storage
        dokumente       Disk      Dokumente
        mm              Disk      Multimedia
        elearning       Disk      eLearning
        IPC$            IPC       IPC Service (mm server)

If you want to connect to a share, you call the command smbclient as follows:

smbclient //mm/mm -U admin

In this case, the share mm is called on the host mm based on the user admin. The command does not end but you are now in a special “Browsing” mode which is indicated by the prompt smb: \>.

In “Browsing” mode you move with the cd command to switch to directories or ls to display the content of the current directory.

With the commands get and put files can be downloaded or uploaded via CIFS.

You don’t need more to be able to determine whether access via CIFS is possible and whether you can access the necessary resources in terms of authorization.

Test the IO performance of hard-disks/disks using Linux

Measurements by means of dd

Measure writing performance. This test can also be used with CIFS and NFS and is relatively objective:

dd if=/dev/zero of=temp.bin bs=1M count=1024 conv=fdatasync,notrunc

The parameter fdatasync only ends the dd command when the data has been completely synced. Instead, you could also use oflag=dsync which also takes caches into account and waits until they have been written.

Um ohne Puffer zu testen empfiehlt sich der Parameter oflag=direct bei dd. Zusätzlich sollte der Schreibcache der Disk ebenfalls mit

To test without a buffer, we recommend the parameter oflag=direct using dd. In addition, the write cache of the disc should deactivated using:

hdparm -W0 /dev/sda

It can be re-activated using:

hdparm -W1 /dev/sda

The reading performance can be obtained with the command

time dd if=/tmp/test.bin of=/dev/null bs=4k

bs should be matched to the source drive.

Before doing read tests, it is recommended to flush the read cache:

echo 3 | sudo tee /proc/sys/vm/drop_caches

In all tests, where caches play a role, the RAM’s performance is of course also decisive!

Determine data throughput

This point complements the information above, but comes from a different source:

if=/dev/zero of=/tmp/test1.img bs=1G count=1 oflag=dsync

Determine latency

This point complements the information above, but comes from a different source:

dd if=/dev/zero of=/tmp/test2.img bs=512 count=1000 oflag=dsync

Measurements using hdparm

To test the performance of the cache, hdparm can be used.

hdparm -Tt /dev/sda

Using -t the performance of buffered read accesses is determined. This test primarily determines the performance between disk, kernel and chipset including system caches. The optional parameter --direct bypasses system caches and shows the direct data throughput between disk, kernel and chipset.

With -T the read cache is tested, this test does not make hard disk access because it only reads from the Linux buffer cache.