Search Results: "ag"

28 July 2006

Michael Janssen: Work and Procrastination: A six-hour study of the (10+2)*5 hack.

Recently I discovered the (10+2)*5 dash courtesy of Merlin over at 43 Folders, and I thought that I would give it a try. The concept is fairly simple: work for 10 minutes, screw around for 2 minutes, repeat 5 times, and voila! you have filled an hour with 5/6 productivity. The first thing that I did was download a Konfabulator widget which keeps track of the time and pops up a warning box when you should be screwing around and working.

I worked for approximately 6 hours under this regime today at my Honeywell job, even though I don't use task lists as diligently as I should there. I found that tasks which I regarded as small were finishing in a snap, partly because I wanted to get them done before the next 2 minute break, and partly because if I didn't finish for a break, my mind didn't just stop thinking about the problem. It was very advantageous to think about something else for 2 minutes and then get back to the action because it was like taking a fresh start. I was using the dash to do some coding (the major portion of my hours right now) - finding bugs that normally would have me staring at the screen for a couple minutes seemed easy when I was just coming back from a break. The only issues which I had with it was when I got interrupted by Workrave rest breaks (I turned off microbreaks) or a coworker. I am definitely doing it again, the next time I have an hour uninterrupted.


Michael Janssen: Serendipity plugin for LiveJournal markup

Serendipity is my blogging software of choice lately, but in the past I was a happy user of LiveJournal. Fortunately, now my friends at LJ can keep up to date with my current blog, because of a great event plugin which mirrors posts here on LiveJournal (configurable of course). On LJ people use markup like [lj user="jamuraa"] in order to make a handy link to the page of the livejournal user in question. I was missing that feature, so I coded up a small plugin for s9y which converts that into [info]jamuraa. This is version 0.1, which only does the user tag. It also works in comments if you enable it. In the future, I hope to add code to detect the user type correctly (on LiveJournal there are other icons for different user types). I also probably should not hotlink to the .gifs on the livejournal servers.

To install, just unzip into the plugins/ directory of your s9y installation.

Download the LJ Markup Plugin 0.1 for Serendipity

Alex de Landgraaf: Debtag AI improvements, Thesis finally moving forward

To hell with all this warm weather. Begin this week my thesis supervisor got back from the States, so I've been getting a much-needed kick under the backside. My thesis is improving with leaps and bounds, and although I've got a lot of work left I've also got a renewed sense of direction. I should find a few minutes somewhere to document, package and upload my python GA-toolkit code, it's becoming pretty neat and allows easy linking of GA's together. Optimizing algorithms sounds boring, and it is, but 'parameter calibration using meta-evolutionary algorithms' has a nice ring to it. In other news, Erich too has given me a much-needed kick regarding the Debtags AI SoC project. I've modified the old ai-tagger to also include the directories each debian package contains: The results are interesting to say the least. Take for example kde-i18n-zhtw in the tagdb changes webinterface. It clearly should get the culture::chinese tag, as it's the KDE Chinese i18n package for crying out loud. Yet, the old tagger gives it a mere 0.0003. Not good. The new tagger? 0.99004. Remarkable what a little bit of extra meta-data can do...

27 July 2006

Michael Janssen: Weekend Weeviews: Omega Man, Conquest of the Planet of the Apes

A month between postings. Who needs regular updates? I've got a few of these weekend weeviews piled up, so I'm going to do them two at a time every couple of days. Omega Man Charleton Heston makes this post-apocalyptic world view quite the masterpiece. Considering his current stance on guns, it is easy to throw a couple of cheap shots at the movie in which he plays a gun-crazed doctor. Thinking you're the only one left in existence has got to be pretty hard on the psyche, and it shows in the character. Robert Neville (Heston's character) obviously doesn't think he's really alone, just the only one left who shouldn't be shot on sight. The rest of the human race was hit by a crappy plague, 28 days later-style. This plague apparently doesn't kill all brain functions, but only crams you into a religious sect which could only be described as luddite. Movies aren't interesting without a love interest, so Heston finds out early about Lisa (Rosalind Cash) who is keeping a set of children who are immune. Robert is also immune, and hopes to create a serum from his blood. This 70's end of the world is remarkably watchable, although it has it's moments of Action Movie. The acting is well done, although the cult of luddites is somewhat overplayed and has strange overtones of vampirism for some reason. Omega Man gets a 7. (imdb, amazon) Conquest of the Planet of the Apes As a child of the 80s, I never saw any of the original Planet of the Apes movies, and always assumed they were campy and not well done. Imagine my surprise when I discovered that they actually have a plot and are interesting. This fourth movie in the series of 70s movies presents it's moral message with a generous heaping of.. it's moral message. Years after his parents travelled backward in time in Escape from the Planet of the Apes, Caesar, the only talking ape left, is incognito with the circus master who raised him and comes to the city for the first time. At this time the plague which killed all pets has already ravaged the nation, humans have decided that apes are more useful as slaves than pets, and already have a large monolithic "Ape Management" section of government. Caesar gets thrown through the system when his "owner" gets brought into questioning for.. questioning the treatment of an ape. Being highly intelligent, he quickly gets snatched up for his skills by a top government official. Starting an underground resistance movement is the next step, and dominos start to fall from there. Conquest.. then degenerates into a large-cast action film, with hundreds of extras in a street-level ape vs. human fight. It's not the most interesting movie ever, but considering my expectations I can happily give it a 6. (imdb, amazon)

Pierre Habouzit: I'm a dangerous criminal

The French Constitutional Council just decided about the DAVDSI law[1] that: The opposition had made a formal request to the CC asking to reject the law, and they got one that is worse than the one proposed by the government. One that is maybe even worse than the DMCA[2]. OMFFSM The small benefit is that the point that said that authors who write softwares that can be used to exchange copyrighted contents has been softened (in fact restricted) a bit. But still remains, which in itself still is a nightmare. (for the non french-speaking people, the picture says this man whistle music without paying it )
Notes [1] law about copyrights and related rights [2] which is a nationnal record I'm not especially proud of

Enrico Zini: Tenth day in Addis

Procedure to check if all the services of Dream University are up and running If a machine blocks pings, use arping instead.
  1. Test DHCP:

    $ sudo ifdown eth0
    $ sudo ifup eth0
    $ ifconfig
    
  2. Test the DNS:

    # See if the DNS machine is on
    # The network
    $ ping -n 192.168.0.1
    # See if the DNS resolves names
    $ host www.dream.edu.et
    
  3. Test the gateway:

    # Ping the gateway
    $ ping gateway
    # Ping an outside host
    $ ping -n 10.4.15.6
    
  4. Test the proxy:

    # Ping the proxy
    $ ping proxy
    # Open a web page and see if it displays
    # See if it caches
    http_proxy=http://proxy.dream.edu.et:3030/ wget -S -O/dev/null http://www.enricozini.org  2>&1   grep X-Cache
    
  5. Test the mail server:

    $ ping smtp
    $ nmap smtp -p 25  grep 25/tcp
    $ if nmap gateway -p 25  grep 25/tcp   grep -q open ; then echo "It works"; fi
    $ send a mail and see if you receive it
    
To do more advanced network and service monitoring, try nagios:
New useful tools seen today:
wget - The non-interactive network downloader.
Special devices:
  • /dev/null:
    • On read, there is no data.
    • On write, discards data.
  • /dev/zero:
    • On read, reads an infininte amount of zero bits.
    • On write, discards data.
  • /dev/random, /dev/urandom
    • On read, reads random bits.
    • On write, discards data.
    • Difference: /dev/random is cryptographically secure, but it can hang waiting for system events
Example uses:
wget -O/dev/null http://www.example.org
dd if=/dev/zero of=testdisk bs=1M count=50
mke2fs testdisk
sudo mount -o loop testdisk  /mnt
Tiny little commands:
  • true - do nothing, successfully
  • false - do nothing, unsuccessfully
  • yes - output a string repeatedly until killed
Example uses:
while /bin/true; do echo ciao; done
Using /bin/false as a shell
yes   boring-tool-that-asks-lots-of-silly-questions
Some more shell syntax:
  • 2>&1 Redirects the standard error in the standard output
  • 2> Redirects the standard error instead of the standard output
Some people run commands ignoring the standard error:
command 2> /dev/null
This causes unexpected error messages to go unnoticed: please do not do it. What to check if a machine is very slow:
  • See if the ram is full:

    $ free
    
    If it is, you see what are the fattest programs using top, pressing M to sort by memory usage.
  • See if there are lots of programs competing for CPU:

    $ top
    
  • Check if you have I/O bottlenecks:

    $ vmstat
    
    (but I don't know how to read it)
  • For a desktop on older hardware, you can try xubuntu instead of ubuntu

More VIM command mode Command mode allows to perform various text editing functions. You work by performing operations on selected blocks of text. Some common operations:
  • y: copy ("yank")
  • p: paste
  • P: paste before
  • d: cut ("delete")
  • c: change
  • i: insert
  • a: append
  • .: repeat last operation
Some common blocks:
  • w: word
  • : paragraph
  • left and right arrow: one character left or right
  • up and down arrow: this line and the one on top or below
  • f letter: from the cursor until the given letter
  • v: selection
  • V: line selection
  • ^V: block selection
Examples:
  • yw: copy word
  • dw: cut word
  • yy: copy line
  • dd: cut line
  • V (select lines) y: copy a selection of lines
  • V (select lines) d: cut a selection of lines
  • p: paste
The best way to learn more vim is always to run vimtutor.
Installing squirrelmail To install squirrelmail:
  1. apt-get install squirrelmail

  2. /usr/sbin/squirrelmail-config and configure IMAP and SMTP. In our case, since we use IMAPS, the IMAP server is imap.dream.edu.et, port 993, secure IMAP enabled and SMTP is smtp.dream.edu.et.

  3. Read /usr/share/doc/squirrelmail/README.Debian.gz (with zless) for how to proceed with setup. A short summary:

    • link /etc/squirrelmail/apache.conf into the apache conf.d directory
    • customise /etc/squirrelmail/apache.conf for example setting up the virtual hosts, or running it only on SSL
To have different virtual hosts over HTTPS, you need to have a different IP for every virtual host: name based virtual hosts do not work on HTTPS. You can configure multiple IP addresses on the same computer: use network interfaces named: eth0:1, eth0:2, eth0:3... These are called interface aliases. You cannot setup interface aliases using the graphical network configuration and you need to add them in /etc/network/interfaces:
iface eth0:1 inet static
      address 192.168.0.201
      netmask 255.255.255.0
      gateway 192.168.0.3
auto eth0:1
This is the trick commonly used to put different virtual HTTPS hosts on the same computer.

Bdale Garbee: Thanks for the Thanks

I don't know quite what's going on this week, but I like it. I receive a fair number of emails every week asking me to do little things related to Debian. For some reason, over the last few days, the percentage of people who are taking the time to send a quick email saying "thank you" for whatever I've done in response to their reqeust has gone way up. Thank you.

Ben Armstrong: Plumbing the depths of cdbs

On #debian-games we were discussing today how opaque cdbs is for those who aren’t intimately acquainted with its inner workings. I want to be able to easily see, at least at the level of detail visible in a purely debhelper-based rules file, what’s going on inside just by running make itself, e.g.
debian/rules -p   grep -v ^#   grep -B1 dh_
Here’s a small excerpt of the output when run on ri-li:
binary-install/ri-li::
        dh_installdocs -p$(cdbs_curpkg) $(DEB_INSTALL_DOCS_ALL) $(DEB_INSTALL_DOCS_$(cdbs_curpkg)) 
        dh_installexamples -p$(cdbs_curpkg) $(DEB_INSTALL_EXAMPLES_$(cdbs_curpkg))
        dh_installman -p$(cdbs_curpkg) $(DEB_INSTALL_MANPAGES_$(cdbs_curpkg)) 
        dh_installinfo -p$(cdbs_curpkg) $(DEB_INSTALL_INFO_$(cdbs_curpkg)) 
        dh_installmenu -p$(cdbs_curpkg) $(DEB_DH_INSTALL_MENU_ARGS)
        dh_installcron -p$(cdbs_curpkg) $(DEB_DH_INSTALL_CRON_ARGS)
...
OK, it’s a bit crude and misses a lot of interesting details, but it is a starting point that can be tweaked to zero in on whatever parts interest you.

Evan Prodromou: 9 Thermidor CCXIV

Mark Jaroski asked if I had any recommendations for Web hosting. I thought I'd share them here. Mostly I find Web hosting really difficult to evaluate -- there are just too many options. It's a really competitive business, and the hosting companies have SEO-saturated the Web hosting keyword at Google. On top of that, there are a ton of fake "hosting comparison" sites -- really just fronts for the bottom-feeders of hosting. When you get to even a good hosting company's Web site, there'll be a lot of flashing lights and gewgaws. A lot of companies try to sell you add-on features you don't need, and they'll have abusive UI to get you to click on the wrong thing, like:
 You're eligible for a big discount on our
 blogging software! Only $3.95 a month! 
 [Continue] Cancel
... where the "Continue" button adds the add-on to your account and "Cancel" is what you need to go on with your order. I think this is borderline fraud, but as far as I know nobody's been shut down or fined for it. For contrast, there are a lot of really good community-oriented and Open Source-friendly hosting services out there, like Montreal's Koumbit. They'll usually be able to devote more time and energy to individuals' technical needs. Often, though, small companies and community groups can't get the same economy of scale and thus price level to compete with the big guys. Of course, what you usually trade away for that $0.75 a month is any customer service or friendliness or control of your own site. The big guys are organized around selling hard to inexperienced people on price, then ignoring their requests for help and treating them like idiots for asking until they go away. Getting help with real problems like server downtime or misbehaviour can be as humiliating as having someone explain what "Cut", "Copy", and "Paste" mean, and probably get you as many over-the-phone eye roll pauses. "My Web site is down!" <eye roll> "Did your AOL Chat window get in front of your browser window, sir?" I think the best option for people is to look around, find a group or company that has a price you can live with and business practices that don't turn your stomach, and give them a try. Make frequent local backups of your site, and be ready to leave if you need to. tags:

Dumb Contest Julien has started a dumb bug reports contest (you be the judge of what "dumb" applies to here). What's the point? I guess if it catches on we can humiliate Debian users and keep them from filing bug reports at all. And as we all know, no bug reports means no bugs, right? Being abusive towards users has never helped a project improve the quality of its software. Our bug tracking system is one of the things that's made Debian a top-tier operating system. Making fun of Debian users for using it is a very bad idea. tags:

Yay Akron The Akron Beacon Journal has an article about suggested Akron-related topics to add to Wikipedia. That seems like a great idea. tags:

Wow Douglas Self has some cool items in his Museum of Retro Technology about old technology -- like this rocket bicycle and this gyro-stabilized monorail. Thanks to Nick Moffitt for the links, even though he probably cribbed them from somewhere lame like Slashdot or Boing Boing. tags:

Supportworthy So, I have two blog items about technical support people looking down on those who are reporting problems. And I was thinking how much I work to gain the respect of technical support people so they'll listen to my problems when I have to make a phone call. As little as I like it, I find myself working to qualify to get my questions answered and my problems fixed. So I wonder: what if there were some kind of standardized computer user certification? You could take a series of increasingly-harder tests at some training centre, and you'd give your certification level (or -- better -- your standardized identification number) when you register software or hardware or when you report a bug. People will then know that when you say, "I think postfix isn't accepting connections!", you might actually have a point. tags:

JAM on it Maj, of course, was the one who pointed me to the page for a new Wiki engine in development. Ho-hum, I know... there's already too many wiki engines. But this one is interesting in that it aims to be MediaWiki compatible and run in a Java Servlet container. That seems like a killer combination for those people who want "the wiki that Wikipedia uses" but with an "enterprise-strength" Web technology. I've only tried the software a little bit, but it definitely looks like it's already more featureful than 70% of Wiki engines. Taking MW as a model is a great idea for a new Wiki engine -- it's an extremely featureful wiki engine that "fits well in the hand" of writers and users. Already the use of images and the special support pages look good on JAMWiki. And the integration of lucene means an excellent search engine -- something MediaWiki lacks out of the box. The Roadmap looks to have some good plans in the future. Anyways, Maj likes JAMWiki since JAM is MAJ backwards. I can't tell you what to make of that, though. What I do know is that the project needs a logo real bad. tags:

Ajax in 10 weeks So, wp:AJAX is no longer as bonerific a word as it was six months ago, but it's still pretty hot. I mean, we've all stopped nattering about how fantabulous Ajaxical UI is, and just started writing code to make it work. It seems like nobody even uses "Ajax" and "Web 2.0" as synonyms anymore (well... I guess only the people who still call it "CGI/PERL".) But I was interested to see when I was looking for the Java Servlets link above that Sun is part of the cryptic Open Ajax Alliance. They've got an Ajax project incubating called jMaki to integrate Javascript programming on the server and on the client. Neato, say I. Most interesting was an external link to a 10-Week Free AJAX Programming Online Course. Starts August 4th, seems like a nice self-training tool. tags:

Stuck in ol' CGI again So, I've been getting some non-deterministic 500 errors from WiLiKi, and I'm starting to think they're concurrency problems with searching the database the WiLiKi pages are stored in. I also think there may be a FastCGI tie-in, so I've rolled-back to CGI for a while to see if it cuts down on the errors. Annoying, indeed. tags:

Romain Francoise: To fold or not to fold

Holger, my blog script expects to find at least one link per entry, failing that it chops off the last line of the last paragraph (in the RSS file). It's because I never post entries without links, supporting them meant additional work, and I'm lazy.

Uwe Hermann: HOWTO: Install Windows XP in Debian using QEMU

This is more or less a reminder for me, most of you will probably already know how to do it...
  1. Install QEMU:
    apt-get install qemu
  2. Create a (resizable) image which will hold Windows XP. The installer chokes if the image is smaller than 1.2 GB or so, but that's not too much of a problem; the "qcow" image format will only take up as much space as is really needed, so the image will be very small in the beginning (not 1.2 GB big!).
    qemu-img create -f qcow /path/to/xp.cow 1300M
  3. Insert the install CD, and install Windows in the QEMU image:
    qemu -hda /path/to/xp.cow -boot d -cdrom /dev/cdrom -m 384 -localtime
  4. Wait.
  5. After the install has finished, shut down the QEMU/Windows; from now on you can boot it (without having to insert the CD anymore) with:
    qemu -hda /path/to/xp.cow -boot c -m 384 -localtime -k de -usb
Type "qemu -h" for more options.

Junichi Uekawa: linux-uvc works.

I've been working on linux-uvc package in Debian.Apparently, it was one of the more awaited packages,I received quite a lot of feedback.It's sometimes refreshing to get a different kind of user reaction to uploads.However, I'd really like to have some kind of mailing listto discuss this stuff. Maybe Cc'ing debian-user will do.

Meike Reichle: What life's been like

It's been quite a while since my last post, so this will mainly be an update on what I've been up to the last weeks or even months. Overall the past time has mainly been pretty busy. It was the end of the semester, a time that always brings a lot of work, and in this case it was the end of my last semester, which adds a little extra pressure to the whole business, since I didn't only have to take care of the usual stuff, but also had to arrange for an appropriate topic for my upcoming thesis, which is always a kind of a "balancing act". Things are however looking good now and I am quite confident that I'll be able to spend the six months I have for my thesis on a subject that actually interests me, my tutors, complies with the official guidelines, has some purpose beyond getting me a Master of Arts AND EVEN has a realistic chance of actually working out! Yay academia! Apart from university work I've been kept additionally busy by my jobs, which unfortunately also both had a kind of peak during the last weeks. The problem about this is, that actually both of them were intended to be "only-jobs" since they both provided me with enough money and consumed just as much time as I could spare during the semester. But then I got accepted for both of them and absolutely couldn't decide which one to chose (one was at the university as a teaching assistant, the other at a pretty cool IT security consultant's) so I did both and have been juggling those two, my studies and actually getting to sleep/eat every now and then during the last weeks. This has been pretty exhausting, but on the bright side, I have a little spare money now to spend while the holidays. (Luckily both bosses are on a 3-4 week trip in August :)) One thing that suffered rather greatly from my very tight schedule this semester (apart from my horribly neglected sweetie of course) was my Debian/Free Software work that got almost entirely stalled ever since I returned from DC6. So I hope to be using the more quiet summer months to spend some time on this, maybe write a nice new talk and package some things I've had my eyes on for quite a while already. Oh, and I'll sleep. A LOT! PS: Last night, to celebrate the end of the semester, we went to see the Pirates of the Caribbean double feature. Hilarious!! Go see it!

Enrico Zini: Ninth day in Addis

SSH To enable remote logins with ssh:
apt-get install openssh-server
Then you can login with:
$ ssh efossnet@proxy.dream.edu.et
To verify the host key fingerprint of a machine:
$ ssh-keygen -l -f /etc/ssh/ssh_host_rsa_key.pub
Note: you need to verify it before logging in! More information at http://www.securityfocus.com/infocus/1806 Example ssh usages:
  • To log in:

    $ ssh efossnet@proxy
    
  • To run a command in the remote computer:

    $ ssh efossnet@proxy "cat /etc/hosts"
    
  • To copy a file to the remote computer:

    $ scp Desktop/july-18.tar.gz efossnet@proxy:
    
  • To copy a file from the remote computer:

    $ scp efossnet@proxy:july-18.tar.gz /tmp/
    
Warning about SSH: there are people who run automated scans for ssh servers and try to login using commonly used easy passwords. If you have an SSH server on the network, use strong passwords, or if you can it's even better to disable password authentication: in /etc/ssh/sshd_config, add:
PasswordAuthentication no
To log in using public/private keys:
  1. Create your key:

    ssh-keygen -t rsa
    
  2. Copy your public key to the machine where you want to log in:

    ssh-copy-id -i .ssh/id_rsa.pub efossnet@proxy
    
  3. Now you can ssh using your RSA key

If you use ssh often, read these:
proxy Problems we had today with the proxy:
  • ssl does not work. Reason: squid tries to directly connect to the ssl server, but the AAU network wants us to go through their proxy. Ideal solution: none. There is no way to tell squid to use a parent proxy for SSL connections. Solution: update the documentation for the Dream university users telling to setup a different proxy for SSL connections. Longer term solution: get the AAU network admins to enable outgoing SSL connections from the Dream university proxy. Other things that can be done:

    • report a bug on squid reporting the need and requesting the feature
    • download squid source code and implement the feature ourselves, then submit the patch to the squid people
  • Browsing normal pages returns an error of 'Connection refused'. In the logs, the line is:

    1153294204.912    887 192.168.0.200 TCP_MISS/503 1441 GET http://www.google.com.et/search? - NONE/- text/html
    
    That "/503" is one of the HTTP error codes. Explanation of the error codes:
    Reason: the other proxy is refusing connections from our proxy. Solution: none so far. Will need to get in touch with the admins of the other proxy to try to find out why it refuses connection to our proxy, and how we can fix the problem.
postfix on smtp.dream.edu.et http://www.postfix.org/basic.html Difference between mail name and smarthost:
  • The mail name is the name of the mail server you're setting up (TODO: need more details on what's it used for)
  • The smarthost is the name of the mail server that will relay mail for you.
Quick way to send test mails:
apt-get install mailx
echo ciao   mail efossnet@localhost
To configure a workstation not to do any mail delivery locally and send all mail produced locally to smtp.dream.edu.et:
  1. install postfix choosing "Satellite system"
  2. put smtp.dream.edu.et as a smarthost.
To setup a webmail: apt-get install squirrelmail (on a working apache setup). To setup mailing lists: apt-get install mailman, then follow the instructions in /usr/share/doc. Mail server issues we encountered:
  • When a mail is sent to efossnet@localhost, the system tries to send it to efossnet@yoseph.org

    Investigation:
    • "yoseph.org" does not appear anywhere in /etc or /var/spool/postfix
    • postfix configuration has been reloaded
    • postfix logs show that the mail has been 'forwarded'
    Cause: the user efossnet had forgotten that he or she had setup a .forward file in the home directory. Solution:
    rm ~efossnet/.forward
    
Apache To add a new website:
  1. cd /etc/apache2/sites-available

  2. sudo cp default course

  3. sudo vi course:

    1. Remove the first line

    2. Add a ServerName directive with the address of your server:

      ServerName course.dream.edu.et
      
    3. Customize the rest as needed: you at least want to remove the support for browsing /usr/share/doc and you want to use a different document root.

  4. sudo a2ensite course

  5. sudo /etc/init.d/apache2 reload

More VIM Undo: u (in command mode) Redo: ^R (in command mode) You can undo and redo multiple times.
To recover a lost password for root or for the ubuntu admin user Boot with a live CD, mount the system on the hard disk (the live CD usually does it automatically), then edit the file /etc/shadow, removing the password:
enrico:$1$3AJfasjJFHa234dfh230:13343:0:99999:7:::
becomes:
enrico::13343:0:99999:7:::
You can edit the file because, in the live CD system, you can always become root. After you do this, reboot the system: you can log in without password, and set yourself a new password using the command passwd.
Installing packages not on the CDs To get a package for installing when offline:
  1. apt-get --print-uris install dnsmasq
  2. Manually download the packages at the URLs that it gives you
Otherwise, apt-get --download-only install dnsmasq will download the package for you in /var/cache/apt/archives. You can install various previously downloaded debian packages with:
dpkg -i *.deb
Backups There are various ways:
  • dump (for ext2/ext3 file systems) or xfsdump (for xfs file systems). Makes a low-level dump of the file system. It must be used for every different partition. It makes the most exact backup possible, including inode numbers. It can do full and incremental backups. To see the type of the filesystems, use 'mount' with no parameters. To restore: restore or xfsrestore.

  • tar Filesystem independent. It can work accross partitions. It correctly backups permissions and hard links. It can do full and incremental backups. Example:

    tar lzcpf backup.tar.gz /home /var /etc /usr/local
    tar lzcpf root.tar.gz /
    
    To restore:
    tar zxpf backup.tar.gz
    
  • faubackup Filesystem independent. Uses hard drive as backup storage. Always incremental. It cannot do compression. Unchanged files in new backups are just links to old backups, and do not occupy space. Any old backup can be deleted at any time without compromising the others. It can be used to provided a "yesterday's files" service to users (both locally and exported as a read-only samba share...). To restore, just copy the files from the backup area.

  • amanda apt-get install amanda-client amanda-server It is a network backup system. It can do full and incremental backups. You can have a backup server which handles the storage and various backup clients that send the files to backup to the server. It takes some studying to set up. To restore: it has its own tool.

Some data requires exporting before backing it up:
  • To save the list of installed packages and the answer to configuration questions:

    dpkg --get-selections > pkglist
    debconf-get-selections > pkgconfig
    
    To restore:
    dpkg --set-selections < list
    debconf-set-selections < pkgconfig
    apt-get dselect-upgrade
    
    If you do this, they you only need to backup /etc, /home, /usr/local, /var.
  • To save the contents of a MySQL database:

    mysqldump name-of-database   gzip > name-of-database.dump.gz
    
    To restore:
    zcat name-of-database.dump.gz   mysql
    
You can schedule these dumps to be made one hour before the time you make backups.
Scheduling tasks As a user:
crontab -e
As root: add a file in one of the /etc/cron.* directories. In cron. hourly,daily,weekly,monthly you put scripts. In the other directories you put crontab files (man 5 crontab). If the system is turned off during normal maintainance hours, you can do two things:
  1. Change /etc/crontab to use different maintanance hours
  2. Install anacron (it's installed by default in ubuntu)
For scheduling one-shot tasks, use at(1):
$ at 17:40
echo "Please tell Enrico that the lesson is finished"   mail efossnet@dream.edu.et
^D
When and how to automate
  1. First, you manage to do it yourself
  2. Then, you document it
  3. Then, you automate it
Start at step 1 and go to 2 or 3 if/when you actually need it. (credits to sto@debian.org: he's the one from which I heard it for the first time, said so well).
Interesting programs to schedule during maintanance
  • rkhunter, chkrootkit
  • checksecurity
  • debsecan
  • tiger
Important keys to know in a Unix terminal These are special keys that work on Unix terminals:
  • ^C: interrupt (sends SIGTERM)
  • ^\: interrupt (send SIGQUIT)
  • ^D: end of input
  • ^S: stop scrolling
  • ^Q: resume scrolling
Therefore, if the terminal looks like it got stuck, try hitting ^Q.
Problems we had today with postfix
  • Problem: mail to efossnet@dream.edu.et is accepted only if sent locally. Reason:

    $ host -t mx dream.edu.et
    Host dream.edu.et not found: 3(NXDOMAIN)
    
    Solution: tell dnsmasq to handle a MX record also for dream.edu.et:
    mx-host=dream.edu.et,smtp.dream.edu.et,50
    
  • The problem not solved with the previous solution. Reason: postfix was making complaints which mentioned localhost as a domain name. Solution: fixed by changing 'myhostname' in main.cf to something different than localhost. Note: solved by luck. Investigate why this happened.

Problems found yesterday and today:
  • there is no way to tell squid to use another proxy for SSL connections: it only does them directly

  • if you want to configure evolution to get mail from /var/mail/user, you need to explicitly enter the path. It would be trivially easier if evolution presented a good default, since it's easy to compute. It would also be useful if below the "Path" entry there were some text telling what path is being requested: the mail spool? the evolution mail storage?

  • In Evolution: IMAP or IMAPv4r1? What is the difference? Why should I care?

  • apt-get --print-uris doesn't print the URIs if the package is in the local cache, and there seems to be no way to have it do it.

  • in /etc/apache2/sites-available/default, is the NameVirtualHost * directive appropriate there? It gets in the way when using 'default' as a template for new sites. Otherwise, one can add a new (disabled) site that can be used as a template for new sites instead of default.

  • the default comments put by crontab -e are not that easy to read.

Felipe Augusto van de Wiel: 27 Jul 2006

Things ready to change again :o)

[Debian]
Keeping you up-to-date about my NM process, I have some good news since last time I wrote here. I was approved in the P&P! And I just sent the answers to T&S Part 1, by far, this was the most time intensive part of the NM until now. I had to fix RC-bugs, write shell script, write manpages and answer another round of questions. It is a hard part of the NM, IMHO, not because of the questions but because of the time required to prepare everything as good as possible. There is always something new to learn about Debian, how the project works, where to find information, how to help, it is really amazing. Extremadura i18n meeting is pretty close and we have a proposal to work in the debian-installer language packs (or something like that) trying to add more languages (and trying to save space or using another approach to load the languages).

Talking quickly about Brazil, August is almost there, our Debian User Group already find a place to celebrate Debian Anniversary, which is great and will allow us to prepare everything in the best way possible to have a very nice event. Translation work is a little bit delayed because CVS pserver is offline and translators without ssh access (non Debian Developers) can't work directly, we are routing our files and patches do debian-www, a huge thanks for all people helping us to get the files commited!


[Random stuff]
University classes are about to begin. Next week (August 31st), let's go for another round. I got visit from my cousing from Sao Paulo and also from my cousins from Netherlands, busy weekend (which delayed a little bit my NM answers, but it was all fun). :-)

I'm trying to get involved with DebConf Organization, we are in the middle of lots of changes. I'm working to get my packages uploaded to get them in "etch" and "in time". I'm also waiting for the new point release of Sarge (r3) so we can update Debian-BR-CDD (r1). Speaking about Debian-BR-CDD, we are ready to migrate to RT which will help to keep the tasks (DebConf Teams also use it).
Hmmm, I would like to write more about lots of things. Not right know, but certainly pretty soon. And by the way, if you don't know, the idea is to get Debian GNU/Linux 4.0, codename "etch", in time for Christmas. :-)

Adam Rosi-Kessel: That&#8217;s Not a Fan!

I’ve been doing some overdue hardware upgrades on my little server/community ISP. 500GB drives have dropped to the $200 range, and while they’re not necessarily the cheapest per gigabyte storage, it’s a so much more efficient use of space and electricity that it seems a waste to buy a smaller capacity drive. So I bought two internal 500GB drives and one external 500GB so I can have a backup some place other than the backup server in my basement, in case the house burns down or someone decides to break in and steal all the computers (note to thieves: please don’t do this). Since I’ve been burning through hard drives (literally!) at a rate of about one every six months, I decided to do something about the temperature in the case. The CPU has been hovering dangerously around 60 degrees celcius for a long while, and the drives well into the 50’s — except the one drive with its own personal fan, which is happy to hang out in the 30’s. (I’ve got three more hard drive fans en route). In any event, I’ve never bought a CPU fan before, so I just picked out a random one that seemed better than what I had. Little did I know what I was getting. When I took the new fan and heatsink out of the box, I was reminded of Crocodile Dundee: That’s not a CPU fan, mate. This is a CPU fan. Pictured below is the TITAN TTC-NK15TB/SC(RB) I bought for the low price of $31. Although this image doesn’t show the Japanese anime decoration on the top, it captures the size. The old fan/heatsink combination was about 20% the size of this one, and not nearly as shiny. I realize for all you case-modder/overclocker/slashdot/gamer types, this is probably a puny cooling apparatus, but for me it was pretty exciting. Now my hands are apparently permanently covered with blue thermal grease, and my CPU is running at a cool 40 degrees. Oh, well, here is the top view: Of course, no one ever sees that, except the person installing it.

John Goerzen: Today's Political Puzzler

So recently the prime minister of Iraq criticized Israel for a disproportionate response in their attacks against Lebanon. I don't know his exact words, but in general, I agree with that sentiment.

It's no big surprise that Bush and Republican leaders have all been rushing to support Israel and taking their sweet time before helping with a ceasefire, and taking plenty of time with that process, too.

So it's also no big surprise that a number of Washington politicians mustered up a good deal of righteous-sounding moral indigniation at the Iraqi PM. There were some that boycotted his address to Congress today. Lots of fiery rhetoric.

But here's the surprise: it was the Democrats doing this.

Huh?

The populist party, the one that's supposed to be valuing life and perhaps has recently started to grow a backbone in opposing ever-broadening war, is now in support of Israel's tactics?

I think it's all politics. The Republicans don't want to criticize the PM because he's part of the process their party started. And the Democrats want to pander to their base and criticize anything related to an unpopular war.

I don't think very many people in Washington from either party have genuine ethics these days. They just take whatever moral position they think will win votes.

Joey Hess: trompe-l&#39;oeil

This might just be artifacts of staring at a screen too much, but: Hmm, it may be time to write my second ever X program. Exporting random "dead" pixels to an open $DISPLAY would be so Evil.

John Goerzen: Thoughs on cfengine, bcfg2, and puppet

Yesterday I posted about my first steps with cfengine. By the end of the day today, I had things far along that I can:



Very nice.

I've had a few annoyances with the cfengine packages support, which doesn't quite seem to work as documented al the time.

I also took a look at bcfg2 thanks to a comment yesterday. It looks very interesting, but I have a few gripes about it. I find cfengine files easier to read. I can look at a file, having never used cfengine before, and have a reasonable idea of what is trying to be done and how it will be accomplished. I can't say the same for bcfg2, plus bcfg2 uses XML config files (ick) and a bunch of small otherfiles. While the architecture as the authors have described it certainly sounds appealing, I'm not sure that bcfg2 is a simple as cfengine. I am a strong believer in the KISS (Keep It Simple, Stupid) principle. But THANKS to the person that left the comment, and I hope that bcfg2 continues to evolve and provide an alternative to cfengine.

I also looked at Puppet. This thing looks very slick. Seems to be cfengine with a nicer syntax. On the other hand, it's not really clear that anybody is using it. That makes me nervous -- this is the kind of thing that can seriously harm machines if it does something unexpected.

Matthew Garrett

Dear Blars,

If you're going to file bugs against my packages, please ensure that I can email you. Rather than, say, blocking what appears to be an entire /16 of addresses. Of which my ISP happens to own a measly /20. I'm aware that your policies may result in some degree of collateral damage, but if you don't want to receive email from me because some ISP that probably isn't in the same cocking country as me[1] doesn't answer their abuse@ email[2] then don't fucking email me in the first place, you astonishing cunt.

Love,

Matthew.

[1] The netblock covers the UK, Switzerland, Georgia, France, Ukraine, Italy, the US, Gibralter[3], Germany, Russia and Lithuania. My ISP, well, doesn't.
[2] I checked. Mine's never received any email from you there, ever.
[3] Yes, I know

Next.

Previous.