Shows the UUID of the given partition (here /dev/sda7). Doesn't need to be root. Show Sample Output
Shows all block devices in a tree with descruptions of what they are.
`blkid` is an interface to libuuid - it can read Device Mapper, EVMS, LVM, MD, and regular block devices. -c /dev/null - Do not use cached output from /etc/blkid.tab or /etc/blkid/blkid.tab (RHEL) -i - Display I/O Limits (aka I/O topology) information (not available in RHEL) -p - Low-level superblock probing mode (not available in RHEL) Show Sample Output
Show the UUID-based alternate device names of ZEVO-related partitions on Darwin/OS X. Adapted from the lines by dbrady at http://zevo.getgreenbytes.com/forum/viewtopic.php?p=700#p700 and following the disk device naming scheme at http://zevo.getgreenbytes.com/wiki/pmwiki.php?n=Site.DiskDeviceNames Show Sample Output
Formats the output from `ioreg` into XML, then parses the XML with `xmllint`'s xpath feature. Show Sample Output
first off, if you just want a random UUID, here's the actual command to use:
uuidgen
Your chances of finding a duplicate after running this nonstop for a year are about the same as being hit by a meteorite before finishing this sentence
The reason for the command I have is that it's more provably unique than the one that uuidgen creates. uuidgen creates a random one by default, or an unencrypted one based on time and network address if you give it the -t option.
Mine uses the mac address of the ethernet interface, the process id of the caller, and the system time down to nanosecond resolution, which is provably unique over all computers past, present, and future, subject to collisions in the cryptographic hash used, and the uniqueness of your mac address.
Warning: feel free to experiment, but be warned that the stdin of the hash is binary data at that point, which may mess up your terminal if you don't pipe it into something. If it does mess up though, just type
reset
Show Sample Output
Remove the dashes from a UUID using bash search and replace. Show Sample Output
piped this to pbcopy (OSX only) you got a uuid in the pasteboard Show Sample Output
Gets the Hardware UUID of the current machine using system_profiler. Show Sample Output
commandlinefu.com is the place to record those command-line gems that you return to again and again. That way others can gain from your CLI wisdom and you from theirs too. All commands can be commented on, discussed and voted up or down.
Every new command is wrapped in a tweet and posted to Twitter. Following the stream is a great way of staying abreast of the latest commands. For the more discerning, there are Twitter accounts for commands that get a minimum of 3 and 10 votes - that way only the great commands get tweeted.
» http://twitter.com/commandlinefu
» http://twitter.com/commandlinefu3
» http://twitter.com/commandlinefu10
Use your favourite RSS aggregator to stay in touch with the latest commands. There are feeds mirroring the 3 Twitter streams as well as for virtually every other subset (users, tags, functions,…):
Subscribe to the feed for: