Linux

  toucheatout  2007-08-15 16:02  Linux  

Linux's bash shell is certainly one of the most comfortable shells around. While reading its (4800+ lined) man page is certainly worth it, here are highlighted some features.

Pattern matching

  toucheatout  2006-10-12 16:43  Linux  

Both Ubuntu and debian use dpkg and apt-get package management system. They work with all those .deb that you encounter. While most often binary packages are used (those that directly install executables, libraries etc in the right place), sometimes the compile options are not those you really would have wanted (for instance some packages in relation with audio/video processing, for codec licensing issues). The source packages repositories are those specified by lines beginning with deb-src in /etc/apt/source.list. Uncomment them if necessary.

  toucheatout  2006-10-04 14:02  Linux  

A word of warning on a unix account potential

A unix account is something that grants in general alot of things you may not be aware of, especially if logging in is possible (That could be such things as a webspace (apache's mod_userdir), cron jobs, email, possibility of running one's own server software on non-privileged ports ...), in case it is on a machine running several services (which can run without anyone noticing). Not mentionned are half a ton of denial of service attacks, at least in the default install case (yet this last point should be considered implied when saying 'giving a unix account that can be used to log in with').

  toucheatout  2006-10-02 10:19  Linux  

Even if it's not considered wise to let clear-form passwords in a file, sometimes there is no possibility of authenticating via public keys and therefore backups are only feasible this non-optimum way...

This script would be suitable for off-site backups. Yet, if you have the possibility, i would advise you to use public-key cryptography (with something like ssh, using rsync for instance) to ensure the proper authentication and secrecy of your data.

  toucheatout  2006-08-09 09:26  Linux  

The tool: dd

Simplest tool from linux toolbox: just reads and writes from stdin to stdout. However, input and output can be specified, including from a raw device. We have then the equivalent of ghost, that is sometimes called a master - that is, a default install that is going to be forced into a computer, for crash recovery but also to automate desktop installs: makes everything the same thus really easier to maintain. Bang your head a tenfold more for one install and avoid banging it again.

Doing ghost-like backup (or master)

Second line includes compression to reduce size - works really well with non-full hard drives:

  toucheatout  2006-08-08 16:34  Linux  

From troubleshooters.com

Generic options for uid mashing

Those are for /etc/exports.

Option

What it does

Comment

  toucheatout  2006-08-07 11:53  Linux  

There are good tools to very closely evaluate a disk or disk array performance. This is especially critical for remotely mounted filesystems, where performance tweaks can turn a shame into a very reasonable and efficient network attached storage.
Bear in mind that it is difficult to take into account the multitude of requests when testing alone, and thoroughly tested system can behave very differently under a load from different sources.

Testing Writes

Replace the bs (as Block Size) by the setting you want to test, then ajust the count to create a file of the size you chose. Try to make it quite (2x) bigger than memory on the server if you are to test reading afterwards. /dev/zero is a good source of quickly grabbed bits...

  toucheatout  2006-05-19 19:09  Linux  

Cryptography, encryption, digital signatures...

Nowadays encryption and digital signature are two cryptographic applications that are bound to be more and more widely used as a replacement of safes and signatures for digital content. While the principles are used since quite some time in protocols like SSH or other VPNs for network trafic and PGP for emails, their use is not as widespread as it "should". We'll show here how to create and use a pair of keys suitable for the use with GnuPG, the open implementation of PGP.

A word on security

The keys that we will be generating can be used under certain legislation as a proof as strong as physical evidence, given the robustness of the algorithm. Given the time/computing power needed to break a GPG keypair, only governemental agencies can afford, so... Pay good attention to keep the private key absolutely secured. Indeed if compromised, the keypair becomes useless for encryption and anyone with it can digitally sign documents with your signature (and it will just look as good as if you made it...).

Creating the keypair and getting the cryptographic infrastructure right

Creation of the keypair

This is simply made with gpg --gen-key. This will ask you various questions about the keypair itself (key size, algorithm, expiration info), and personal info associated with the key. The defaults are usually sensible for the keypair parameters/.
Once created, the keys have to be somewhat exported so that people can sue them. It also would be good that the keys get signed by well-known persons (at least those that you intend to communicate with). Likewise, keys from your peers have to get known to the system (i.e. import them).

Exporting your (public, of course) key

gpg --export [keyID].

Exports all keys if keyId not present. Redirect the output or use the -o switch to indicate an output file.

Importing your peers' keys

When you want to add public keys from your peers, as you could have guessed, use the command:
gpg --import < key_file

Build your web of trust

So we can sign things now... put a mark that you in person approve of digital stuff. The other way, people can use you public key to encrypt messages only issued for you.

  toucheatout  2006-05-19 10:32  Linux  

Generate your pair of keys

ssh-keygen -t rsa
should simply do the trick and generate
~/.ssh/id_rsa and ~/.ssh/id_rsa.pub
that is a keypair suitable for ssh version 2. When prompted for a passphrase, leave it blank (just hit return).
The passphrase is skipped as the only critical piece of information is the private key (~/.ssh/id_rsa), that is mode 0700 in a 0700 directory so it should be fine. And the actual aim is to get instantaneous though secure login, not input a password anymore.

To create a stronger key than the default (1024 bits), use the -b switch (argument 2048, resp. 4096, even down - min 512).

  toucheatout  2006-03-26 18:52  Linux  

Choose your religion

Linux comes in a variety of flavors. It may very well end up the same core tools, the same linux kernel, it will have different default level of control, different administration tools, different package management systems and different filesystem layout. Choosing one's distro doesn't really matters in the end, yet each represents a certain state o find on how to organize the architecture.

Check out the subcategories for specific information.

 
yro.slashdot.org - Your Rights online


nytimes.com New York Times - International