Boot Debian Linux in Console/Text/Terminal at Start-up

Boot Debian Linux in Console/Text/Terminal at Start-up:


You can boot your debian machine to Console/Text/Terminal mode do so by disabling your login manager such as KDM, GDM or XDM from running at boot time.


To disable the login manager from automatically running at boot up, run the following command as root

# update-rc.d -f kdm remove

Replace kdm with gdm or xdm if they are what you use.

To start X manually, you would then have to login at the command prompt and enter the command:

$ startx

To reset your login manager so that it runs at boot up, do:

# update-rc.d -f kdm defaults



*NOTES:

- The $ sign at the start of the command is to signify the terminal's prompt, no need to type this in
- The # sign at the start of the command is to signify the root user's terminal prompt, no need to type this in

Animated wallpaper on Linux Desktop with XWINWRAP

Animated Wallpaper on Linux Desktop with XWINWRAP:


Download and Install xwinwrap to have animated wallpaper from shantz-xwinwrap @ http://tech.shantanugoel.com/projects/linux/shantz-xwinwrap

Alot of people seem to be having problems with this app with icons, well for me I don't use icons anyways,
and even in this article I assume if you do try it, that you don't use icons, for me its just more clean anyways.

You can actually use a media player like mplayer to play a video as the background if you like with xwinwrap app, however for this example I keep it simple by using the matrix screen saver found in most linux distros, especially debian and debian based ones.


At the website it instructs to using:

- To run glmatrix in fullscreen wallpaper mode

$ ./xwinwrap -ov -fs -- /usr/lib/xscreensaver/glmatrix -root -window-id WID


- To run glmatrix in a small window wallpaper mode

$ ./xwinwrap -ov -g 400x400+400+200 -- /usr/lib/xscreensaver/glmatrix -root -window-id WID


- To run glmatrix in small circle wallpaper mode

$ ./xwinwrap -ov -g 400x400+400+200 -sh circle -- /usr/lib/xscreensaver/glmatrix -root -window-id WID


- To run glmatrix in small triangular wallpaper mode

$ ./xwinwrap -ov -g 400x400+400+200 -sh triangle -- /usr/lib/xscreensaver/glmatrix -root -window-id WID


However, I ran into some problems and I tried several combinations of the options, I would get the whole screen with the animation eating up all my windows/apps/panels even, I found a solution that works, but as I said earlier, I do not use nor have tested it with icons, try the following command if it works out for you:

To run:

$ xwinwrap -ni -o 1 -fs -s -st -sp -b -nf -- /usr/lib/xscreensaver/glmatrix -root -window-id WID

To stop use pkill as below:

$ pkill xwinwrap


(Tested working in LMDE LinuxMint XFCE 4.8, Debian Sid (Unstable) KDE 4.8)


*NOTES:
- I suggest using ALT+F2 and inputting the command/s there, instead of on console prompt, however if you do use a console append an "&" w/o the quotes a the end with a space separating it from the rest, this will indicate to run it on the background so that you wont kill the program by terminating console when you do.
ex:
$ xwinwrap -ni -o 1 -fs -s -st -sp -b -nf -- /usr/lib/xscreensaver/glmatrix -root -window-id WID
to
$ xwinwrap -ni -o 1 -fs -s -st -sp -b -nf -- /usr/lib/xscreensaver/glmatrix -root -window-id WID &
- The $ sign at the start of the command is to signify the terminal's prompt, no need to type this in.



Boot LinuxMint Debian (LMDE) in Console/Text/Terminal at Start-Up



Boot LinuxMint Debian (LMDE) in Console/Text/Terminal at start up:


Edit /etc/default/grub to boot LinuxMint Debian into console mode, You shouldn't just sudo nano /boot/grub/grub.cfg and put "text" there, there's a big warning against it at the top of the file.

The right way is to:
$ sudo nano /etc/default/grub


And add "text" to GRUB_CMDLINE_LINUX_DEFAULT.
So if it looked like:

    GRUB_CMDLINE_LINUX_DEFAULT="quiet"

...you have to change it to:

    GRUB_CMDLINE_LINUX_DEFAULT="quiet text"

update grub

$ sudo update-grub

And reboot.

This method is preferred over disabling a service, since it's what it should be: editing one line in a configuration file. The same process can be repeated, and, if you want, startx will bring you to the user graphical interface while in text mode.

To return to normal, of course, just edit the file again and update-grub.

*NOTES:


- The $ sign at the start of the command is to signify the terminal's prompt, no need to type this in
- Doesn't seem to work in Vanilla Debian Sid (Unstable) do not use this unless you want to never boot in X/GUI, if you ever did do this, you can fix it by changing the grub defaults in CLI, then update-grub and restart.

Add Audio to a Video file in Linux with FFMPEG

Add Audio to a Video file in Linux with FFMPEG:

$ ffmpeg -i input.mp4 -i input.mp3 -vcodec copy -acodec libmp3lame output.flv


*NOTES:
- Where input is the source file and output the outcome file.
- The $ sign at the start of the command is to signify the terminal's prompt, no need to type this in.
- Many file formats are supported, for more see $ man ffmpeg

Convert .MPG Video to a Compressed .AVI in Linux with Mencoder


Convert .MPEG/MPG Video to a Compressed .AVI in Linux with Mencoder:

1.) xvid

$ mencoder -ofps 25 -ovc xvid -oac mp3lame -lameopts abr:br=128 -srate 48000 -xvidencopts fixed_quant=4 input.mpg -o output.avi

/or

2.) x264

$ mencoder -ofps 25 -ovc x264 -oac mp3lame -lameopts abr:br=128 -srate 48000 -xvidencopts fixed_quant=4 input.mpg -o output.avi



*NOTES:
- Where input is the source file and output the outcome file.
- The $ sign at the start of the command is to signify the terminal's prompt, no need to type this in.
- Using x264 option than xvid will make it the better compressed file, approx 10-30% smaller, this is my preferred conversion of the two.

Screencasting in Linux with FFMPEG

Screencasting in Linux with FFMPEG:

Open a terminal and issue the command below to start recording a video screencast of your desktop -


$ ffmpeg -f x11grab -s wxga -r 25 -i :0.0 -sameq /tmp/output.mpg

press CTRL-C to exit.

*NOTES:
- Where output is the outcome file.
- The $ sign at the start of the command is to signify the terminal's prompt, no need to type this in.
- You can name your file and folder to where the video will be saved whatever you like, in this tutorial I just use /tmp and output.mpg as the destination directory and outcome file name.

3 Ways to Join/Merge .AVI video files in Linux:


3 Ways to Join/Merge .AVI video files in Linux:



1.) avimerge

Issue the avimerge command as such:

$ avimerge -i b1.avi b2.avi b3.avi b4.avi b5.avi b6.avi b7.avi -o output.avi



2.) mencoder

Issue the mencoder command as such:

$ mencoder -oac copy -ovc copy file1.avi file2.avi file3.avi -o output.avi




3.) cat & mencoder

Issue the cat command to string together or concatenate the binary .avi files:

$ cat foo1.avi foo2.avi foo3.avi > output.avi

(this will string all binary .avi files first but the sync of audio and video might likely be broken, so follow the next instructions below to fix it.)

after issuing the cat command and getting the final file output from it, issue the following meconder command from the mplayer package:

$ mencoder -forceidx -oac copy -ovc copy input.avi -o output.avi




*NOTES:
- Where input is the source file and output the outcome file.
- the $ sign at the start of the command is to signify the terminal's prompt, no need to type this in.
- The order you set the files to be joined or merged from left to right will be the sequence it will playback as one video file.
- Though for me avimerge is my preferred tool for this task.
- If the header file is broken in the final .avi use the avifix command part of the transcode package, as such:

$ avifix -i input.avi

/or

$ avifix -i input.avi -f 30,1

(this changes the header of the file input.avi and sets the frame rate to 30 fps.)