tag:blogger.com,1999:blog-21248318507934354112018-03-18T11:14:55.520+00:00Linux Tipps, Fixes & MoreYour Linux Self-Help Desk. A selection of mostly Linux related tutorials, howtos, fixes, news and more.D.noreply@blogger.comBlogger43125tag:blogger.com,1999:blog-2124831850793435411.post-9317051446073125932015-05-16T11:17:00.002+01:002015-05-20T18:49:35.021+01:00The Ultimate Setup Guide for ownCloud on Small Systems such as the Raspberry PiIt took me about a year to collect this information. There are many guides, but all I found are incomplete. Here&#39;s the one guide to rule them all - hopefully. The guide works on Ubuntu and Debian without changes. It&#39;s optimized for resources, speed, security and ease of use. While this runs well on my old phone (ARMv7; 512 MB; ~1000 BogoMIPS), it should run even better on a Raspberry Pi.<br><a href="http://linux-tipps.blogspot.com/2015/05/the-ultimate-setup-guide-for-owncloud.html#more">Read more »</a><div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com0tag:blogger.com,1999:blog-2124831850793435411.post-22809862381901697822013-05-09T18:27:00.004+01:002013-05-09T18:59:44.336+01:00Automatically Resume from Suspend to Ram and Suspend to Disk to Save Battery in LinuxSuspending to RAM is allows the system to quickly wake up. But Suspend to Disk allows the system to completely power off, saving more power. That&#39;s why I&#39;ve written a small script for modern Linux systems, which wakes up the system from S3 (memory sleep) and puts it into S5 (hibernation) mode. Also, it prevents you from losing data, because eventually your system&#39;s battery will run out.<br><a href="http://linux-tipps.blogspot.com/2013/05/automatically-resume-from-suspend-to.html#more">Read more »</a><div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com1tag:blogger.com,1999:blog-2124831850793435411.post-36346203210443618252012-02-28T13:49:00.003+00:002013-01-10T12:31:00.114+00:00Regex made easy - Great Regex constructor websiteA great tool to help you construct regular expressions is this website: <a href="http://draft.blogger.com/%5C" http:="http:" target="_blank" txt2re.com="txt2re.com">txt2re.com</a>. Thanks a lot to the genious who is so good at regex he can create a tool to create them. You may now imagine me tipping my hat.<div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com1tag:blogger.com,1999:blog-2124831850793435411.post-37336356466873102942011-08-30T06:49:00.001+01:002011-08-30T06:49:20.391+01:00How to run Android in a Virtual MachineBrighthub has a nice<a href="http://www.brighthub.com/hubfolio/matthew-casperson/blog/archive/2011/07/03/installing-android-x86-in-virtualbox.aspx"> howto for installing Android x86 in a VirtualBox Virtual Machine</a>. This way you can run android apps on your computer -- with a fair speed as opposed to with the android emulator that comes with the android sdk.<div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com0tag:blogger.com,1999:blog-2124831850793435411.post-72119130258993848902011-05-08T21:18:00.001+01:002011-05-16T07:06:22.888+01:00Accessing Kindle 3 with SSH via Wifi using usbNetwork and LaunchpadAs a prerequisite you will need usbNetwork and launchpad installed and working. Once that is set up, create a new file in the launchpad directory: iptables.ini with the contents<br><a href="http://linux-tipps.blogspot.com/2011/05/accessing-kindle-3-via-wifi-with.html#more">Read more »</a><div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com0tag:blogger.com,1999:blog-2124831850793435411.post-26461831428752423262011-01-07T10:36:00.001+00:002011-01-07T10:36:11.417+00:00Step by Step Tutorial to the Android Development SetupCheck out this great screenshot-laden extensive <a href="http://www.linuxconfig.org/get-started-with-android-application-development-using-linux-and-android-sdk">tutorial to setup Eclipse and the Android SDK</a>.<div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com0tag:blogger.com,1999:blog-2124831850793435411.post-88319892886125155062010-12-14T06:26:00.007+00:002010-12-14T15:54:25.797+00:00Make your Android power efficient in any situation (for free!)In the following post I will explain how to use <a href="http://www.appbrain.com/app/cpu-tuner-(rooted-phones)/ch.amana.android.cputuner">cpu tuner</a>, a completely free and open source <i>app</i> for android. All you need is root and some time. It&#39;s a follow up on and summary of my various related posts you can mostly see below (&quot;related posts&quot;) on working with governors to increase power efficiency in Linux. This is of course something that a) Linux and b) Android and c) your phone manufacturer should already have done. But as they didn&#39;t...<br><br><a href="http://linux-tipps.blogspot.com/2010/12/make-your-android-power-efficient-in.html#more">Read more »</a><div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com13tag:blogger.com,1999:blog-2124831850793435411.post-19821369874068743702010-09-27T11:48:00.002+01:002010-11-18T13:25:59.519+00:00Eduroam with Linux (incl. Android!)The guide my university supplied did not work after all with Linux. So I used an alternative guide, which also turned out to be working for Android:<br /><br /><b>Security: WPA2 Enterprise</b><br /><br /><b>Authentification Tunneled TLS (TTLS)</b><br /><br /><b>Anonymous Identity: </b>none<br /><br /><b>CA-Certifikate:</b> (none)<br /><br /><b>Inner Authentification: MSCHAP2</b><br /><br />User: user@your-uni.com (as in the Windows settings guide of your home university)<br />password: your password, as in windows.<div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com0tag:blogger.com,1999:blog-2124831850793435411.post-9117255744025303272010-08-15T10:29:00.021+01:002010-12-14T15:54:50.725+00:00Syncronized Folders across Windows and Linux - (Cloud-)Free Encrypted Cross-Platform Synchronisation with UnisonI always wanted to sync a few folders of my system across all my computers. E.g. the my scripts directory, where I constantly fiddle with my scripts and create new ones, my documents I always want to be able to have and edit everywhere, etc. I would never know where the most current version is without bothersome comparison of the dates. I would have to check every file and then copy the newer one. But that's now history, thanks to unison and my sync scripts.<br /><br /><b>What you need</b><br />The biggest problem is that you need a Linux server somewhere that is best constantly running and connected. I sync all my files with an online server. This is not a big deal because with SSH the connection is securely encrypted. Also due to compression and the fact that files are only transferred once, sync is pretty fast even with an ADSL connection. Of course this won't work for slow dial up connections in combination with large files. But as long as there are only small changes in certain files, even dial up might work for you. A Linux server is not really needed, but makes the setup much easier, which is why that's what I demonstrate here. And of course if you only want to sync two computers with each other, then there's no need for a constantly active server. It should work with Mac as a client or even server, but I don't own one so I can't help with that.<br /><br /><b>Downloads</b><br />You can get your unison <a href="http://alan.petitepomme.net/unison/index.html">downloads for Mac, Windows here</a> and for <a href="http://www.seas.upenn.edu/~bcpierce/unison//download/releases/beta/">Linux here</a> (Ubuntu binaries i386 for <a href="https://launchpad.net/~groetschel/+archive/ppa/+files/unison-gtk_2.40.16-1ubuntu1~ppa2_i386.deb">9.10</a> and <a href="https://launchpad.net/~groetschel/+archive/ppa/+build/1697665/+files/unison-gtk_2.40.16-1ubuntu-lucid~ppa3_i386.deb">10.04</a> and <a href="https://launchpad.net/~groetschel/+archive/ppa">more in this ppa</a>. I recommend version 2.40.16, read below for why.<br /><br />For Windows you also need to get Putty Agent (Pagent), Putty Puttygen and Plink <a href="http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html">get them at http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html</a>. For Linux you also need openssh-server ssh-agent, ssh-keygen (in the openssh-client package) and keychain. You need to setup a working ssh connection with public key authentication for this to work without your interaction in the background. See <a href="http://pkeck.myweb.uga.edu/ssh/">here</a> how to do this.<br /><br /><b>Bugs in the past</b><br />At the time I found it, over a year ago, it was still pretty buggy. It couldn't handle unicode, special characters or Umlauts properly. Especially between different system you'd end up with two differently named versions of a file unless you restricted yourself to normal a-z characters - very annoying.<br /><br />But recently new version has come out, which fixes the problem. Now unison is not only a tool to synchronize flawlessly across different systems, it's also faster and prettier "GUI" than older versions and it still synchronized across encrypted ssh connections if you want it to. In my view this makes it the perfect tool for my needs. I've set it up to synchronize my laptop and my netbook with each other and my server system over ssh.<br /><br /><b>How it works</b><br />It's blazingly fast by only copying those parts of the files that have changed. And it doesn't transfer any files to check this. It runs both on the server and the client and only transfers the dates and hash coddes of the files via a secure compressed ssh connection. You can find out more about unison <a href="http://www.linuxjournal.com/article/7712">at LinuxJournal</a>.<br /><br />The easiest setup and the one I will show here is a star topology setup. This means there are several client systems synchronizing with one server. It works because unison knows which files are newer. The great side effect is that you automatically have a distributed backup on all your systems - the server and all clients of all your files.<br /><br />The script runs automatically every X minutes in the background via cron on Linux (completely invisible) and is called by the Windows Task Manager on Windows (almost invisible).<br /><br /><b>Important to know</b><br />You need to use exactly the same version on all system you deploy it. There are easy to install packages for Debian and Ubuntu and precompiled versions for Windows. I haven't worked with OS X version yet, but they should work as well. I use a Linux server, Windows on the server side should be possible to set up but it's going to be much more difficult. Setting up the client on Windows is already non-trivial.<br /><br />As you don't modify the same file on both systems at the same time before a server sync, then there won't be any problems. If you do, unison will not sync them. You need to call unison by itself and it will prompt you to chose how to deal with the situation.<br /><br />The Linux version uses the symlink feature of Linux to let you configure which folders to sync on the go. In Windows this won't work, so all your folders you want to sync need to be inside one parent folder. I know no way around this, though the unison config file might have a solution somewhere...<br /><br /><b>Sync script:</b><br /><blockquote>#!/bin/bash<br /><br />LOG="tee -a $HOME/logs/mysync2.log"<br />source $HOME/scripts/functions $HOME/scripts/variables<br /><br />main ()<br />{<br />echo Starting at $(date)<br /><br /># exit if running on battery<br />grep on-line /proc/acpi/ac_adapter/*/state &gt;&gt; /dev/null<br />if [ ! $? ]; # 1 if not "on-line"<br />then<br />echo Running on battery. Leaving now...<br />exit 0; <br />else<br />echo Running on AC Adapter.<br />fi<br /><br /># use ssh-agent<br />source $HOME/.keychain/*-sh 2&gt;&amp;1<br />echo sock $SSH_AUTH_SOCK pid $SSH_AGENT_PID me $(whoami)<br />ssh-add -l || (echo "SSH Key not active\!"; ssh-add || exit 1)<br /><br />cd $HOME<br /><br />unison-2.40.16 sync -batch -maxbackups 2 ${@} 2&gt;&amp;1<br /><br />echo Exiting at $(date)<br />}<br /><br />main | $LOG</blockquote><br />It checks and exits when the system is running on battery. To be able to work in the background, it uses ssh-agent. So you need to <a href="http://pkeck.myweb.uga.edu/ssh/">setup ssh key authentication</a>.<br /><br /><b>Unison config in ~/.unison/sync.prf:</b><br /><blockquote># Unison preferences file<br />root = /home/user/sync<br />root = ssh://user@syncserver:port/syncfolder<br />follow = Path *<br />ignore = Path {scripts/s3.sh}</blockquote><br />This is a sample config file. It follows all symlinks in the $HOME/sync folder to syncfolder on syncserver via ssh. The ignore section shows you how to exclude certain files from synchronization.<br /><br /><b>Windows Setup</b><br />This should already work just fine in Linux. Now let's turn to the Windows client.<br /><br />The Window setup, as you will see, it much more "fun". There are several steps you need: Putty Agent (Pagent), Putty Puttygen and Plink (see above for links) and then a few bash scripts.<br /><br />You need to copy your private ssh key from your linux box and convert it to putty's format with puttygen. Then copy it into a safe folder. I have it in the same folder as the Unison.exe. Then setup an ssh connection to your server with Putty that uses the key and save it to profile name unisonssh. Copy the following bash files to your unison folder and adjust the path names accordingly.<br /><br /><b>Putty Agent.bat:</b><br /><blockquote>pageant.exe sshkey.ppk</blockquote>This needs to be a script or otherwise it's not started in the right folder and won't find the key. Try it with the full path of the key file then. This must be linked into Autostart if your and will prompt you for your ssh key password if your key is password protected.<br /><br /><b>SSH Connect.bat</b><br /><blockquote>@plink -C -ssh -load unisonssh -i "C:\unison\sshkey.ppk" -l djtm -P 22 unison -server -auto </blockquote>Change the path to where your ssh key lies and the port to your server's port if necessary.<br /><br /><b>Unison Sync.bat</b><br /><blockquote>C:<br />cd "C:\unison\"<br />unison2.4.exe -sshcmd sshconnect.bat -backups -backupdir unisonbackups -backuplocation central -batch -confirmbigdeletes -contactquietly</blockquote><br />Testing it<br />Now is a good chance to try everything works fine. Try creating a file one one system and see how after two syncs it magically appears on the other. Edit it there to see how the edits are transferred back to the first system.<br /><br /><b>Scheduling it</b><br />Once everything works you can schedule it to run regularly without you needing to do anything. In Linux, you should install keychain for this to work in scripts and then enter the following into your cron. (To edit your cron type <i>crontab -e</i>)<br /><blockquote>*/15 * * * * $HOME/scripts/unisonsync</blockquote>The */15 means to sync every 15 minutes. Don't worry, usually nothing will be done - I hardly ever notice anything happening. Of course the path should be where your unison sync script lies.<br /><br />In Windows it's a tad more difficult again. The most difficult part of it all is to make it run in the background without annyoing you every 15 minutes or so. The following command looks a bit quirky, but that's the best I could do. Enter exactly this behind Execute: in the task scheduler.<br /><blockquote>cmd /C start /LOW /MIN "Unison Sync" "C:\unison\unison.bat"</blockquote>and "C:\unison" next to execute in. Check both execute only when logged in and, under the settings tab, not to start the task if you're running on battery.<br /><br />And now - <i>finally</i> - enjoy great, free, in sync folders!<br /><br />Another older, less detailed guide is available <a href="http://jan.essert.name/2008/11/on-using-unison-to-synchronise-files-efficiently-between-windows-and-linux-machines/">here</a> and <a href="http://www.linuxjournal.com/article/7712?page=0,1">here</a>. Thanks to the authors of Unison.<div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com0tag:blogger.com,1999:blog-2124831850793435411.post-48256348982373694732009-12-27T12:51:00.003+00:002009-12-27T12:58:28.586+00:00How to Boot Floppy Disks with Grub e.g. to upgrade your BIOSIf you have a modern notebook, it's likely you don't have a floppy drive. But still, many companies offer either floppy images or windows tools to upgrade your BIOS. Both not really great for Linux users. Of course, you can use the tools of <a href="http://www.openfirmware.info/">OpenBIOS</a>, but that can be pretty difficult. Here's how you can boot any floppy directly in memory via grub:<div><br /></div><div>1. You need to get memdisk. It's included in the syslinux package.</div><div><br /></div><div>2. You copy memdisk to your boot folder:</div><div>e.g. cp /usr/lib/syslinux/memdisk /boot/memdisk</div><div><br /></div><div>3. You uncompress (if it's zipped) and copy your floppy image to the boot folder, e.g. to /boot/floppy.ima.</div><div><br /></div><div>4. You create the grub entry, use your normal values for root and the path:</div><div><div></div><blockquote><div>title Floppy Image</div><div>root (hd0,0)</div><div>kernel /boot/memdisk</div><div>initrd /boot/floppy.ima</div><div>boot</div></blockquote><div>5. Reboot, select it. It should boot normally, only without the annoying floppy drive noise. Done!</div></div><div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com1tag:blogger.com,1999:blog-2124831850793435411.post-84111980163780125012009-05-20T21:33:00.002+01:002009-05-20T21:34:42.901+01:00Booting Linux over the NetworkHere's a quick <a href="http://www.pcplus.co.uk/content/tutorial-boot-linux-over-network">how to</a>.<div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com0tag:blogger.com,1999:blog-2124831850793435411.post-83671006386404744942009-05-03T18:45:00.008+01:002009-05-03T19:32:10.223+01:00Pretending a Package is Installed by Creating an Empty Package with Checkinstall (for Debian-based Distributions)After installing <a href="https://wiki.ubuntu.com/ffmpeg">ffmpeg from svn with checkinstall</a>, I had the problem that the also installed library libavcodec51 is not compatible with the one delivered with Ubuntu. But I could not simply uninstall it so that the manually installed version was used because that caused problems with libxine1-ffmpeg, which stopped kaffeine, amarok and other software from running properly.<br /><br />Unfortunately, checkinstall's --provides option did not work as expected. So I had to find a way to have them use the manually installed version I compiled from svn and hiding that fact that my package manager. I had to let the package management system know the package was already installed.<br /><br />So I ended up creating an artificial package that only has the same name and a similar package version, but no actual contents. Create an empty directory, place the following Makefile into it and execute the following checkinstall command. You may need to adjust the parameters for different packages, refer to the output of apt-cache policy <span style="font-style: italic;">somepackage</span> for an appropriate version number)<br /><blockquote><u>Makefile:</u><br /><br />install:<br /> install -d /usr/local/bin<br /><br /><u>checkinstall commands:</u><br />checkinstall --nodoc --install=no --pkgname=libavcodec51 --pkgversion=3:0.svn$(date +%Y%m%d)-12ubuntu5<br />checkinstall --nodoc --install=no --pkgname=libavutil49 --pkgversion=3:0.svn$(date +%Y%m%d)-12ubuntu5<br />checkinstall --install=no --nodoc --pkgname=libavformat52 --pkgversion=3:0.svn$(date +%Y%m%d)-12ubuntu5<br />sudo dpkg --install ./*.deb<br />sudo ldconfig<br /></blockquote><br /><br />This elegantly fixed the error "ffplay: symbol lookup error: /usr/local/lib/libavcodec.so.52: undefined symbol: av_gcd" and "ffmpeg: error while loading shared libraries: libavformat.so.52: cannot open shared object file: No such file or directory" for me.<div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com10tag:blogger.com,1999:blog-2124831850793435411.post-20825819109424348232009-03-31T12:45:00.001+01:002009-03-31T12:47:05.417+01:00Make your Firewall Safer with KnockdHere's a nice <a href="http://www.go2linux.org/how-to-connect-to-your-PC-opening-the-firewall-iptables">howto</a>. It describes how to install, configure and test knockd.<div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com0tag:blogger.com,1999:blog-2124831850793435411.post-44313015856521266132009-03-22T13:17:00.023+00:002009-05-23T11:46:50.406+01:00"Never use the second pass encoding again" - Using 'Constant Ratefactor' Instead of Average Bitrate in x264Okay, I may not be able to completely fulfill that promise, but you will most likely be saved from the second pass and thus a lot of encoding time quite often with this tip. If you don't need the resulting file to e.g. fit on a CD, Constant Ratefactor aka Constant Quality is probably perfect for you. Let me supply you with a quick overview and my quick mencoder script that does the job.<br /><br />Did you know you can use a roughly vorbis-like quality selection, constant quality <a href="http://mewiki.project357.com/wiki/X264_Settings#crf">crf</a> even in x264? This will save you a lot of encoding time with <a href="http://forum.handbrake.fr/viewtopic.php?f=5&amp;t=6567#p38179">more or less the same quality</a>. Or <a href="http://forum.handbrake.fr/viewtopic.php?f=5&amp;t=6567#p41845">maybe not</a>? Well it will look different, but it <a href="http://forum.handbrake.fr/viewtopic.php?f=5&amp;t=6567#p41854">should be fine</a>. For x264 a range of 18-26 is <a href="http://mewiki.project357.com/wiki/X264_Settings#crf">recommended</a>. The higher the number the lower the bitrate and thus the file size will be.<br /><br />Nice! Finally I don't need to adjust and calculate bitrates myself anymore! The algorithms really seem to work, because when I now change the codec settings to more efficient ones (e.g. increase the frameref, subq or enable mixed_refs) the quality (SSIM) remained pretty similar, while the bitrate sank.<br /><br />Some experience with the parameters: The mixed_refs parameter did regularly increase the SSIM for me, but also took a lot more time to encode. Frameref=2 increases the efficiency with little performance impact in my experience. I wonder why it's not the default. Bframes decrease the quality slightly but shave a lot off the bitrate and even increase performance a bit for me.<br /><br />Let me show you my "quick" example script for mencoder.<br /><blockquote>#!/bin/bash<br /><br />CRF=23.5 # 21-26 recommended, the higher the smaller the resulting file, see http://mewiki.project357.com/wiki/X264_Settings#crf<br /><br />INPUT="$1"; shift<br />X264OPTS="$1"; shift<br />OUT=`basename "$INPUT"`"-x264.avi"<br />echo Encoding $INPUT to $OUT<br /><br />mencoder="time nice /usr/bin/mencoder -quiet -cache 16384"<br />enc="$mencoder -ovc x264 -oac copy -x264encopts crf=$CRF:trellis=1:frameref=2:bframes=2:8x8dct:psnr:ssim:$X264OPTS"<br /># I suggest nr= of no more than 2 or 3 with current x264 from svn.<br /># something along the lines of -vf<br /># eq=contrast=20:brightness=2,hue=saturation=1.25 for bleak videos<br /># denoise3d for noisy and unsharp=l:3x3:1.045 for blurry videos.<br /># I recommend to try out the result with mplayer first.<br /># A combination of all may work well, too.<br /><br />echo $enc -o "$OUT" "$INPUT" $*<br /><br />[ -f "$OUT" ] &amp;&amp; echo File exists &amp;&amp; exit 1;<br /><br />$enc -o "$OUT" "$INPUT" $*<br /><br /># You can call the script like this:<br /># script.sh input [x264encopts] [mencoder parameters]<br /># $ sh menc.sh somefile.mpg "interlaced" "-vf crop=..." or<br /># $ sh menc.sh somefile.mpg "" "-vf crop=..." or simply<br /># $ sh menc.sh somefile.mpg<br /># to get the right crop settings try $ mplayer -vf cropdetect<br /></blockquote><br /><br />Feel free to get out the flame thrower - or just make some productive comments.<div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com0tag:blogger.com,1999:blog-2124831850793435411.post-38068640449703600182009-03-21T07:10:00.012+00:002009-12-28T18:39:51.993+00:00How To: Comfortably Make your own WINE BottlesIf you're installing a few programs in WINE, you may notice that they tend to influence each other negatively. The fix is to install them in completely different operating system environments, also known as WINE bottles. This way it's easy to completely remove applications by just deleting their "bottle". Let me show you how to make this effortless with standard WINE and a simple shell script.<br /><br />The script is the key part. You tell it a directory where you want your bottles installed and then it will create a new folder each time you install a program. Of course you may also install several programs into one bottle. Let's call the script wine-bottle, which I suggest to put into your $PATH:<br /><blockquote><br />!/bin/bash<br /># wine-bottle v. 0.2<br /># (c) 2009 Linux-Tipps.blogspot.com, (c) 2009 Joost @ http://home.student.utwente.nl/j.vanderhof</blockquote><blockquote># newest version at http://linux-tipps.blogspot.com/2009/03/how-to-make-your-own-wine-bottles.html<br /># published under the GPL v. 3.0 http://gplv3.fsf.org/<br />INSTALLDIR="$HOME/.wine/bottles"; #Set this to where you want to put your Wine bottles<br />[ $# -lt 1 ] &amp;&amp; #if you gave no parameters<br />echo "Please give me parameters! Usage:" &amp;&amp;<br />echo "Execute a program : $0 \"BottleName\" \"Program\"" &amp;&amp;<br />echo "Configure a bottle : $0 --conf \"BottleName\"" &amp;&amp;<br />echo "List bottles : $0 --list" &amp;&amp;<br />exit 1;<br />[ $# -lt 2 -a $1 != "--list" ] &amp;&amp; #if you didn't give the right parameters<br />echo "Please give me at least two parameters or a --list parameter! Usage:" &amp;&amp;<br />echo "Execute a program : $0 \"BottleName\" \"Program\"" &amp;&amp;<br />echo "Configure a bottle : $0 --conf \"BottleName\"" &amp;&amp;<br />echo "List bottles : $0 --list" &amp;&amp;<br />exit 1;<br />[ $1 == "--list" ] &amp;&amp; #if you want to list the bottles<br />echo "Wine bottles in $INSTALLDIR:" &amp;&amp;<br />ls -1 $INSTALLDIR &amp;&amp;<br />exit 1;<br />[ -d "$INSTALLDIR" ] || ( #if installdir is not existing<br />echo "Root of Wine bottles not existing: $INSTALLDIR" &amp;&amp;<br />mkdir "$INSTALLDIR"<br />) || ( #if installdir creation failed<br />echo "Could not create installation Directory: \"$INSTALLDIR\"." &amp;&amp;<br />exit 1);<br />which wine || ( #if wine is not found<br />echo "Wine not found, please install it first" &amp;&amp;<br />exit 1);<br />[ $1 == "--conf" ] &amp;&amp; #if you wish to configure a bottle<br />WINEPREFIX="$INSTALLDIR/$2/" winecfg &amp;&amp;<br />exit 1;<br />#finally, the only remaining possibility is you want to run an application<br />PREF="$1";<br />shift; #drop first parameter to leave the command with its parameters<br />WINEPREFIX="$INSTALLDIR/$PREF/" wine "${@}";</blockquote><br />You can now use this script almost like wine. The only difference is that you first need to tell it the bottle's name. E.g. wine-bottle lingopad setup.exe installs the program inside setup.exe into the bottle lingopad. I suggest using the "create Desktop short cut" option of installers, as it lets you easily start them later, without the need to use this script.<br /><br />If you want to create a backup of your bottle, simpy put the bottle directory inside $INSTALLDIR together with the related .desktop file into an archive. If you want to manually start a program, you can of course still use wine-bottle from the shell: e.g. wine-bottle lingopad "$HOME/Wine/lingopad/drive_c/Program Files/Lingopad/Lingopad.exe".<br /><br />You may also want to install a current wine via the <a href="http://linux-tipps.blogspot.com/2009/03/extensive-list-of-great-ubuntu.html">wine ubuntu repository</a>.<br /><a href="javascript:void(0)"></a><br />Let me know if you liked this howto!<br /><br />Update: Updated to Joost's version, thanks!<div><br /></div><div>Update2: It seems my script has inspired "Joost". He's created a version including a simple GUI. Check out his <a href="http://home.student.utwente.nl/j.vanderhoff/linux.htm">website</a>.</div><div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com10tag:blogger.com,1999:blog-2124831850793435411.post-87835081845642818762009-03-15T19:25:00.004+00:002009-03-15T19:27:35.978+00:00How to Remove Grub from your Boot Sector(MBR) but keep the Partition TableIt's one really easy command, if you know what it is ;)<br />sudo dd if=/dev/zero of=/dev/XXX <span style="font-weight:bold;">bs=446</span> count=1<br /><br />That helps you to remove any boot sector from that device, e.g. sda. But make sure you've got a boot sector somewhere! I can recommed installing grub to a USB stick for backup purposes.<div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com0tag:blogger.com,1999:blog-2124831850793435411.post-63343007710337926412009-03-15T14:31:00.003+00:002009-03-15T14:34:17.005+00:00How To Add Knoppix to your USB StickIf you've got a large USB stick, there's a high chance you will have some space left for <a href="http://www.knoppix.net/wiki/USB_Based_FAQ">installing a current Knoppix on it</a>. That way you can save a few CD-Rs as you need not write a new CD when a new Knoppix comes out.<div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com0tag:blogger.com,1999:blog-2124831850793435411.post-58100072018716040032009-03-15T13:59:00.005+00:002009-03-18T17:26:10.397+00:00Install Daily Fresh Ubuntu Directly over the WebIf you're doing a fresh installation and you don't have a CD downloaded yet, I can recommend the <a href="ftp://archive.ubuntu.com/ubuntu/dists/jaunty/main/installer-i386/current/images/netboot/ubuntu-installer/i386/">netboot installer</a>. It let's you download and install the freshest packages from a mirror near you. All you need as preparation is e.g. a USB-Stick that boots into grub. Checkout this <a href="https://help.ubuntu.com/community/Installation/NetbootInstallFromInternet">howto</a>.<br /><br />Basically all you need to do is copy <a href="ftp://archive.ubuntu.com/ubuntu/dists/jaunty/main/installer-i386/current/images/netboot/ubuntu-installer/i386/">the kernel "linux" and the initrd "initrd.gz"</a> to your stick. Then boot them from Grub and you can start your installation.<br /><br />The great thing about it: During the installation you can chose whether to install Kubuntu, Xubuntu, Ubuntu, etc. And you will automatically get the newest available packages right away. There's no need to fetch and install updates after the installation.<br /><br />And getting the newest packages right away might save you a lot of trouble because of bad packages in the installation cd. And the network installer itself also gets updated regularly.<div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com0tag:blogger.com,1999:blog-2124831850793435411.post-74653440570845677552009-03-14T09:07:00.004+00:002009-03-14T09:14:02.414+00:00What packages are installed in Debian/UbuntuHowtoforge has a nice article on <a href="http://www.howtoforge.com/record-installed-deb-packages-in-a-text-file-ubuntu-debian">how to install the packages you've installed on another computer</a>. It's written for debian and ubuntu systems, including step by step screen shots for doing it in Ubuntu with Synaptic. Here's how you can do the same thing in CLI(also in that article):<br /><br />sudo dpkg --get-selections "*" > package_list<br />and<br />sudo dpkg --set-selections < package_list && sudo apt-get -u dselect-upgrade<br /><br />Oh and from the article's comments: The method only works well if you use the exact same version of Ubuntu on both computers. Let me add that it only works at all if you have the same /etc/apt/sources.list and sources.list.d/* files on both computers.<div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com0tag:blogger.com,1999:blog-2124831850793435411.post-58405521193816853692009-03-13T08:09:00.004+00:002009-03-13T08:17:12.573+00:00Flashing your BIOS with a bootable CDHere's a quick <a href="http://www.linux-sxs.org/hardware/flash_boot_cd.html">howto</a>. I think it would probably be much easier if you'd just use a 2.88 MB floppy image which I think is supported as well. Also be aware that flashing your BIOS from a CD is not supported by most vendors and thus might even void your warranty. But hey, at least you won't need to install Windows.<div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com0tag:blogger.com,1999:blog-2124831850793435411.post-43722035276843982942009-02-28T00:42:00.002+00:002009-03-20T17:38:24.184+00:00Use your ssh-agent for cron scripts with keychainHere's a great <a href="http://www.ibm.com/developerworks/library/l-keyc2/">IBM howto</a> explaining how to use your ssh-agent for cron scripts with keychain.<br /><br />Related: <a href="http://linux-tipps.blogspot.com/2009/02/copy-your-ssh-public-key-to-another.html">Copy your public SSH-Key to another Computer.</a><div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com0tag:blogger.com,1999:blog-2124831850793435411.post-79794591271856428322008-12-30T23:12:00.002+00:002008-12-30T23:12:53.962+00:00Quick&Secure Complete Network Tunnel over SSHSee this <a href="http://blog.crash-override.net/index.php/206">howto</a>.<div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com0tag:blogger.com,1999:blog-2124831850793435411.post-50923660186557656432008-12-19T18:49:00.003+00:002008-12-19T18:50:08.516+00:00How to Speed Up your Website's Page Loading Times with Apache and .htaccess<a href="http://bobcares.com/index.php/blog/?p=211">http://bobcares.com/index.php/blog/?p=211</a><div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com0tag:blogger.com,1999:blog-2124831850793435411.post-38526486144120721182008-11-07T22:06:00.003+00:002008-11-07T22:07:54.866+00:00Setting up NXA <a href="http://www.linuxplanet.com/linuxplanet/tutorials/6575/1/">tutorial</a> how to set up the IMHO best remote desktop connection: NX.<div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com0tag:blogger.com,1999:blog-2124831850793435411.post-18483969943695260652008-11-05T17:34:00.002+00:002008-11-05T17:35:32.160+00:00OpenOffice 3.0 in Ubuntu 8.10Here's a quick <a href="http://tombuntu.com/index.php/2008/10/14/install-openofficeorg-30-in-ubuntu-804-and-810/">guide</a>. It's all about downloading it and installing the deb files... ;-)<div class="blogger-post-footer">(...)
-- Click to read the entire post.</div>D.noreply@blogger.com0