Oldie but goodie

From: http://linuxshellaccount.blogspot.com/2009/02/valentines-day-linux-and-unix-ascii-art.html


Renewing things:

Had a print server and a switch right next to each other, but I was using a 5-6 foot cable to attach them together. I did not want to cut the good cable and I did not want to go out and buy a specialy ethernet cable at the store. I did have a cable that needed repair. took the good cable from the switch/print server and put it where the bad cable was. took the bad cable and cut it to length and added a new end. Two birds killed with one stone sort of.


One of my primary concerns is how to maximize computer resources. For example if you upgrade the memory on a laptop, you usually end up removing the the old memory. If the memory is still good why chunk it?  Had an old thin client that I bought for a few bucks, but it really needed more memory. Forgotten all about the unit untill I was checking out what thin clients could be used with the newer thin client server,. Low and behold, after looking inside the the client, it had a slot that looked just like the same form factor as the memory from the laptop.

Awesome.  Now I can upgrade a thin client to work with my newer LTSP server!!  One more piece of equipment back to work. The memory turned from a lemon into lemonade. Or as I started with “Upgrade one and then upgrade two.”  Reuses for computers III is out! See it at: http://www.instructables.com/id/Reuses-for-legacy-computers-III/


Pentium 1 back to work with Slackware 14



Harvest the parts from your dead equipment. Generally passive parts like the power connector do not go bad. Here we liverated the power connector for another project. may not seem like much, but befroe you know it you are saviang some real money. you did not have to spend at the electronics store. You might even be able to reuse the pcmcia wireless card for an old laptop.

Today was sort of thin client day. Updated the LTSP server. Then I decided for the heck of it to see what of my Compaq EVO T30 clients would work with the server. I had tried on before and it did not work. At the time I really did not investigate why. Today I did take the time to see what was going on. Apparently the thin client did not have enough ram (needs 64 megs) to boot. I happened to look inside the unit and saw there was a holder for a dime that very much resembled a laptop memory slot. went to the parts closet and took out the old dimms I had culled from laptops that have long since died. Would they fit. Yes they did! The non-EDO ram worked just fine. The thin client now worked with the latest server. Ended up upgraded a few more from spare parts.  So I do not need the old server I had to keep the thin clients happy. I need a new mythtv server. Kill two birds with one stone. I will probably save the hard drive and put in a new drive for the mythtv install.

But there was another part. I had one thin client that was password protected. That led me to want to reflash the unit. Do not have Compaq’s fancy Rappaport installer software. But there is a program called netxfer that will do the job. I had used it once, but not very successfully. This time I did a bit of research. Normally I avoid using Redmond Washington software like the plaque, but netxfer does not run on linus out of the box. So I pulled out the old system from the mothballs that would run the software. God it is slow. Cranked it up and downladed the firmware for the thin client I needed to reflash. At least I thought It was the right software. Apparently there are two kinds of firmware downloads one for the Rappaport oftware and one for the netxer software. having downloaded the wrong version, I was pulling out my hair frustrated why the netxfer could not deal with it. So I looked at the files and found that I was using the wrong version. Back to the net to download the right version.  After extracting the files it was time to try again.

To use the netxfer software you have to have sort of a direct connection via ethernet via a switch where the internet and your local dhcp server is not involved. Luckily all I had to do was disconnect one cable. Then your have to set the ipaddress of the netxfer host to with a net mask of I set the gateway to to insure there were no problems. With the bootp.bin (had to be renamed from the downloaded source filesnames, Everything should of been ready. So I started netxfer. The I went to the thin client and turne it on holding down the P key.  Then it started it;s sequence to look for a host to download the firmware from. Both machines sat idle for a bit and the the firmware upload to the thin client started. the upload . The upload did not take that long. Then the thin client once it received the files started unpacking and installing the files. That did take a bit. Once all that was done, the thin client rebooted on it’s own. Tada, the unit was useful again. One word of caution is that if either the upload or the unpacking is interrupted by a power outage, you can wave good bye to the thin client. I would definitely use a ups on botht he xetxfer host and the thin client to not have to worry about power issues..

There are a couple of good instructables that allow you to use the compaq evo thin clients in other ways. Definitely going to look at them.


After playing with my Nexus 7 for a while, I wanted to transfer some files to the unit. There were programs such as a spreadsheet that I wrote to work with qbasic.  Dosbox will certainly run qbasic.  Since Adosbox was available for Android I went and downloaded that. So far so good. Or so I thought.  Now how do I get the files to the Nexus 7. Can not use a usb drive. Hmmm. You pay for and then download an application that would get your files from a usb stick without being root. Why should I pay for something that should of come with the unit to begin with.

Now it is time to think out of the box. Well if I can download files from a web page without root, why can I not do that with a web server of my own? But how to do it. Alhough I do have an Apache web server set up, what about the times when it may not be available. Aha! The quickie web server (see links below) can be the answer. So I copied the files where I wanted to serve the files to the Nexus 7. then made sure they were there.

$ ls -al
total 284
-rwxr-xr-x  1 www-data www-data  16533 2013-02-05 11:11 file1.exe
-rwxr-xr-x  1 www-data www-data  16533 2013-02-06 10:11 file2.exe
-rwxr-xr-x  1 www-data www-data  37213 2013-02-05 11:11 file3.exe
-rwxr-xr-x  1 www-data www-data    212 2013-02-06 10:28 index.html
-rwxr-xr-x  1 www-data www-data 194309 2013-02-05 11:11 qbasic.exe

Did not have to, but I made a simple table of contents or index.html  That way it was clear what I really wanted to download. A good idea especially if you have a lot of files in the directory.

Now to download the files. So I pointed the web browser to oesrvr1/nexus7 if I was using the apache web server.

Just lick on the link… (if using a regular browser, it might look like this:

If you are using the quickie python web server without the index.html, it might look something like this. (You would connect to a port (8000) instead of the directory.)

Obviuously this is not a secure method of transferring files. But on your own private network, that should not be an issue if you are careful. The files were easily transfered to the Nexus 7 and I am happily using them now. Did not have to purchase a special app or worry about how to connect to the Nexus 7 with hardware. Which leaves me to say, If you have one or more computers, having a web server just just as important as having a flashlight for emergencies.


On MSwindows you will need some kind of mtp program that will recognize the Nexus 7.

With linux use gmtp to transfer files via the gui

With linux specifically Debian linux from the command line, you can:

# HOWTO Mount Nexus or MTP Device in Debian or Ubuntu

# Install MTP and its tools:
sudo apt-get install mtpfs mtp-tools

# Create a mountpoint:
sudo mkdir -p -m 777 /mnt/nexus

# Install mod fuse (or permanent in /etc/modules):
sudo modprobe fuse

# Plugin your Nexus
# Ignore the “New Device found” notification

# Mount the device manually instead:
mtpfs /mnt/nexus

# Open your favourite file manager and go to /mnt/nexus and transfer files
# When finished, don’t forget to dismount the device:

sudo umount /mnt/nexus

Linux quickie web server
Windows XP quickie web server

Xp mtp hints:

Linux quickie web server
Windows XP quickie web server


Home made thin client: not dead yet diskless Pentium 1 233 mhz with 128 meg ram pxe booted into LTSP!



Love these little gadgets. They allow you to use either compact flash or the memory cards (depending on the interface) Allows you to carry around an os without carrying around a hard drive that would be subject to bumps that can damage a traditional hard drive. There also maybe sata versions, but I have not really looked for one. If you have a system that supports sata, a usb drive should work just as well.  They are also great for allowing a computer to almost work like an embedded system. You can get the compact flash versions for both desktop pata and laptop pata versions.Inan earlier article you have see the picture of the pc router using the compact flash adapters.


In fact one was used in the pc router instructable:



Quickie hangman game in bash:

$ ./hangman1
** You’re trying to guess a word with 7 letters **
Word is: ……. Try what letter next? a
Good going! The letter a is in the word!
Word is: ….a.. Try what letter next? e
Sorry, the letter “e” is not in the word.
Word is: ….a.. Try what letter next? i
Good going! The letter i is in the word!
Word is: .i..a.. Try what letter next? r
Sorry, the letter “r” is not in the word.
Word is: .i..a.. Try what letter next? s
Sorry, the letter “s” is not in the word.
Word is: .i..a.. Try what letter next? t
Sorry, the letter “t” is not in the word.
Word is: .i..a.. Try what letter next? d
Sorry, the letter “d” is not in the word.
Word is: .i..a.. Try what letter next? l
Sorry, the letter “l” is not in the word.
Word is: .i..a.. Try what letter next? s
You’ve already guessed that letter. Try again!
Word is: .i..a.. Try what letter next? n
Sorry, the letter “n” is not in the word.
Word is: .i..a.. Try what letter next?

blank=".................." # must be longer than longest word

 case $(( $$ % 8 )) in
 0 ) echo "pizzazz" ;; 1 ) echo "delicious" ;;
 2 ) echo "gargantuan" ;; 3 ) echo "minaret" ;;
 4 ) echo "paparazzi" ;; 5 ) echo "delinquent" ;;
 6 ) echo "zither" ;; 7 ) echo "cuisine" ;;

 # This function replaces all '.' in template with guess
 # then updates remaining to be the number of empty slots left

 while [ $letter -le $letters ] ; do
 if [ "$(echo $word | cut -c$letter)" = "$guess" ] ; then
 before="$(( $letter - 1 ))"; after="$(( $letter + 1 ))"
 if [ $before -gt 0 ] ; then
 tbefore="$(echo $template | cut -c1-$before)"
 if [ $after -gt $letters ] ; then
 template="$tbefore$guess$(echo $template | cut -c$after-$letters)"
 letter=$(( $letter + 1 ))

remaining=$(echo $template|sed 's/[^\.]//g'|wc -c|sed 's/[[:space:]]//g')
 remaining=$(( $remaining - 1 )) # fix to ignore '\n'

letters=$(echo $word | wc -c | sed 's/[[:space:]]//g')
letters=$(( $letters - 1 )) # fix character count to ignore \n
template="$(echo $blank | cut -c1-$letters)"
remaining=$letters ; guessed="" ; guesses=0; badguesses=0

echo "** You're trying to guess a word with $letters letters **"

while [ $remaining -gt 0 ] ; do
 echo -n "Word is: $template Try what letter next? " ; read guess
 guesses=$(( $guesses + 1 ))
 if echo $guessed | grep -i $guess > /dev/null ; then
 echo "You've already guessed that letter. Try again!"
 elif ! echo $word | grep -i $guess > /dev/null ; then
 echo "Sorry, the letter \"$guess\" is not in the word."
 badguesses=$(( $badguesses + 1 ))
 echo "Good going! The letter $guess is in the word!"
 addLetterToWord $guess

echo -n "Congratulations! You guessed $word in $guesses guesses"
echo " with $badguesses bad guesses"

exit 0


Take a picture and convert it to an html file.
$ jp2a –color –html –fill –background=light  hs.jpg –output=hs.html






Italian tostadas


Good day.