Archive for the ‘code’ Category
2010
06.28
Tags: 7za, 7zip, backup, bash, gzip, keyless ssh, login, scp, ssh, tar
Posted in bash, code, linux, sysadmin | No Comments »
It’s a simple one-liner that one tends to forget (that is, one that I forget as I untar more than I manually tar). So creating a tar file from directory and all subdirectories is as simple as
tar -cvf file.tar directory (more…)
2010
06.19
Tags: bash, Mac, port forwarding, putty, ssh, terminal, tunnel, windows
Posted in bash, code, linux, mysql, security, sysadmin, windows | No Comments »
Assuming you have a Windows machine and you interact with Linux boxen at any stage, chances are high that you have used and interacted with PuTTY at one stage or another. That beautiful, less than 2 sec, 444K download of a tool (currently at version 0.60 beta) allows you to SSH, COM-direct, RSH, Telnet etc from the desktop. Both examples below relate to MySQL port tunneling.
SSH Tunnels using the Bash command line
Running on a proper machine (or even a Windows with Cygwin or a Mac Terminal) allows you to quickly tunnel a session to a remote server: (more…)
2010
06.15
Tags: 10.04, apt-get, hangs, mysql, ubuntu, upgrade
Posted in bash, code, mysql, sysadmin | No Comments »
There are a lot of words about the MySQL upgrade on Ubuntu 10.04 (64 bit specifically, perhaps the 32bit version too?) — it just hangs:
You get the hopeful message:
Preparing to replace mysql-server-5.1 5.1.41-3ubuntu12.1
but then nothing happens and everything just hangs. (more…)
2010
06.05
Tags: adobe acrobat, adobe reader, exploit, flash, in-the-wild, vulnerability, zero-day
Posted in code, security, sysadmin | No Comments »
From Adobe‘s advisory:
A critical vulnerability exists in Adobe Flash Player 10.0.45.2 and earlier versions for Windows, Macintosh, Linux and Solaris operating systems, and the authplay.dll component that ships with Adobe Reader and Acrobat 9.x for Windows, Macintosh and UNIX operating systems. This vulnerability (CVE-2010-1297) could cause a crash and potentially allow an attacker to take control of the affected system. There are reports that this vulnerability is being actively exploited in the wild against both Adobe Flash Player, and Adobe Reader and Acrobat. This advisory will be updated once a schedule has been determined for releasing a fix.
Adobe Flash Player 10.0.45.2, 9.0.262, and earlier 10.0.x and 9.0.x versions on Windows, Macintosh, Linux and Solaris are affected, as well as Adobe Reader and Acrobat 9.3.2 and earlier 9.x versions for Windows, Macintosh and UNIX. So it’s kinda big. What to do? (more…)
2010
06.04
Tags: document storage, high availability, high performance, JSON, meta data, mongo, open source, php, RDBMS, scalable, vork
Posted in code, linux, open source software, php, sysadmin | No Comments »
MongoDB has been around for a while now, with the current version of production-level code at 1.4.3. Full integration to PHP is available via PECL, across platforms, or precompiled binaries. And yes, it’s Open Source.
From the site itself, MongoDB puts itself out there as a database that bridges the gap between key-value stores (which are fast and highly scalable) and traditional RDBMS systems (which provide rich queries and deep functionality), and is geared toward document-type storage. It supports Map/Reduce for proper high-speed iteration through high volumes of data, allows for easy replication and HA (high availability – but you knew that already). Who uses it? Sourceforge, bit.ly, github and the New York Times, to name a few, use MongoDB in production, as does disqus, and shutterfly. It outputs JSON-style data structures.
MongoDB (from “humongous”) is a scalable, high-performance, open source, document-oriented database. (more…)
2010
06.04
Tags: file sharing, samba, sharing, ubuntu
Posted in bash, code, security, sysadmin | No Comments »
To enable symlinks in Samba for filesharing across platforms inWindows, modify
/etc/smb/samba.conf
and add in the [global] section:
follow symlinks = yes
unix extensions = no
There has been some discussion about
wide symlinks = yes
However, due to the attack vector on Samba servers from Windows allowing file traversion, back in February 2010, you may want to force-set wide symlinks to no– it works without that declaration and is set to no by default.
2010
06.02
Tags: cheat sheet, fileserver, howto, migration, samba, ubuntu, user management, windows server
Posted in bash, code, Did you know, linux, sysadmin, windows | No Comments »
Samba. Whopping goodness. Here are a few notes that help in the setup – from user creation, to directory settings etc
This blog post contains a few lessons learnt and thus by extension a migration plan from a Windows file server to a Samba-based one running on Ubuntu 10.04 LTS. I look at users, system vs smbpasswd user creation and linking (set that up in Webmin before you start, as well as for groups), share setups, general permissions and some very basic troubleshooting (as there weren’t many troubles, just headaches.) (more…)
2010
05.31
Tags: bash, howto, install, sh, ubuntu, webmin
Posted in bash, code, Did you know, linux, sysadmin | 2 Comments »
Just a quick note (as I keep forgetting, and a cut-and-paste solution is a quicker time to market) – but you knew that already. Installing Webmin is quite simple (download directly, or from the mirrors). Currently, 1.510-2 is the latest version – check on www.webmin.com for further details. As an aside, the book Webmin Kompakt – by Holger Reibold – is available for download!
So here’s a simple step-by-step: (more…)
2010
05.14
Tags: events, security, security summit, web security
Posted in bash, code, conferences, javascript, linux, mysql, open source software, php, security, synch.cc, sysadmin, windows | No Comments »
So the Security Summit 2010 has come to an end. Featuring speakers such as Moxie Marlinspike, Joe Grand and Jeremiah Grossman (again), it’s a pity to say that there wasn’t much new that was presented. With repeated concerns about input- and output-validation, as the OWASP Top 10 for 2010 highlight and were used as a repeated example, and a call for a holistic approach to a company’s security posture, the idea of making the thought (and practice) of security part of the organisation’s culture came through over and over again. (more…)
2010
04.25
Tags: bash, command line, Exchange, imap, pop3, shell, telnet
Posted in bash, code, linux, sysadmin, windows | No Comments »
It’s quite simple, really: POP3 (Exchange, dovecot etc) you know, IMAP (Exchange, dovecot, courier etc) you know — so this is just a recap, right? You know how to telnet into the machine — in Vista or Windows 7, you may need to install it separately using “Add/Remove Programs”, or just use Putty in Telnet mode… otherwise, apt-get install telnet if it’s not on your machine (or yum install telnet)
POP3:
telnet SERVER 110 (more...)
2010
04.16
Tags: clamav, clamav-milter, clamd, end of life
Posted in code, Did you know, security, sysadmin | No Comments »
clamav finally sent the end-of-life payload yesterday evening – 0.96 is the current version, so it’s been a good run 
Possible symptons you experienced:
- Repeated notifications:
WARNING: getpatch: Can't download daily- - All freshclam mirrors are ignored
- Your mailq fills up with detailed MAILER-DAEMON messages referring to the End-of-Life nature of clamav 0.94
- (… add your own here…)
But they warned they’d do this in October 2009:
Starting from 15 April 2010 our CVD will contain a special signature which disables all clamd installations older than 0.95 – that is to say older than 1 year.
This move is needed to push more people to upgrade to 0.95 .
We would like to keep on supporting all old versions of our engine, but unfortunately this is no longer possible without causing a disservice to people running a recent release of ClamAV.
The traffic generated by a full CVD download, as opposed to an incremental update, cannot be sustained by our mirrors. (more…)
2010
04.09
Tags: dual-boot, gnu, groff, links, mingw32, sed, vmware, wget, whois, windows, wubi
Posted in bash, code, linux, sysadmin, windows | No Comments »
You’re stuck on a Windows box. But you don’t want to install MinGW32? Can’t dual-boot to run Ubuntu or Debian on your Windows machine for some for that GNU happiness that sed, groff, wget, whois and all those happy apps bring with it? (more…)
2010
04.03
Tags: service, synch.cc, sysaudit, system audits, windows
Posted in code, Did you know, synch.cc, sysadmin, windows | No Comments »

Now you get to kick back - a dog's life!
It’s up – the full network and business system audit and asset tracking service by synch.cc, tracking hardware, software and assets using a background scheduler – more at systemsaudit.co.za!
A systems auditing service with clean reporting and charts like this has never been easier!
Had to just add a plug for it here, too 
And the picture of the puppy was just too cool to resist!