What Have You Done with Linux Lately?

Associate
Joined
21 May 2007
Posts
1,464
Below is me bro's example file. I've pasted it rather than my current active one because his shows how to use more ATTRs to determine the device. For my drives, I used their serial number (found using fdisk or cfdisk I think), which worked a treat for the 4 newer, aluminium sleeved ones, but went a bit t*ts up when it came to the two older black plastic shrouded ones....they both have the same serial number...oooops, not been able to determine a satisfactory way to tell them apart yet. Also my WD passport 320 2.5" seems to change it's serial at random, as fast as I change the rule, it sorts itself out with a new serial to scuper me....most most odd indeed. I think you can use volume ID, and that would certainly fix all my problems, but it has thusfar eluded me.



steve@hal9000 ~ $ cat /mnt/work/06-usb-drive-rules.rules
# these rules generate rules for the my Sony Ericsson Phone.

SUBSYSTEMS=="usb", ATTRS{manufacturer}=="Sony Ericsson" \
ATTRS{idVendor}=="0fce", ATTRS{idProduct}=="e039", ATTR{size}=="399527
\
KERNEL=="sd*1", SYMLINK+="sonye-sd%n" OPTIONS="last_rule"

SUBSYSTEMS=="usb", ATTRS{manufacturer}=="Sony Ericsson" \
ATTRS{idVendor}=="0fce", ATTRS{idProduct}=="e039" \
KERNEL=="sd*1", SYMLINK+="sonye-int%n"

# these rules generate rules for my USB hard disks
SUBSYSTEMS=="usb", ATTRS{serial}=="035E045402E1" \
KERNEL=="sd*1", SYMLINK+="freecom1"

SUBSYSTEMS=="usb", ATTRS{serial}=="152D203380B6" \
KERNEL=="sd*1", SYMLINK+="freecom2"

SUBSYSTEMS=="usb", ATTRS{serial}=="FD300300D888" \
KERNEL=="sd*", SYMLINK+="hitachi%n"

SUBSYSTEMS=="usb", ATTRS{serial}=="00101000100000003437" \
KERNEL=="sd*1", SYMLINK+="mp3player1"

SUBSYSTEMS=="scsi", ATTRS{model}=="USB-DRIVEUNIT " \
ATTRS{vendor}=="FUJIFILM" \
KERNEL=="sd*1", SYMLINK+="fuji-finepix-a210"


Note that the convention "sd*1" limits each rule to the first partition on each drive, this can of course me adjusted.
 
Caporegime
Joined
18 Oct 2002
Posts
29,491
Location
Back in East London
created a ghost image with one command, not a mouse click in sight.

manipulated serial usb modems and created udev events similar to the first reply.

Created a minimal system for deployment; an entire system in less than 20mb. I laugh at windows on this fact alone. X environment adds another 50 or so mb.

Loads of stuff.. sed, grep, piping, etc. etc. on a daily basis.
 
Associate
Joined
2 Dec 2003
Posts
357
follow up

How long did it take to compile the kernel? How much customization did you do to it, or did you just run with the base options as many do?

I assume that the hypervisor-crippled Cell still supports 64-bit operation. Is that what you're running? Does the proc and kernel support Altivec? If so it should have the guts to play most "scene" H.264 .mkv files.

Kernel didn't take too long. Maybe 10 mins, wasn't really watching as I just set it away in another SSH window. Compiled with -j3 so it used both cores of the PPU. Started with def_ps3config then stripped out some stuff. Since then I've recompiled with FUSE support (the def_ps3config didn't have it) - so the PS3 can mount RARs. Also found a GIT patch to support 2.60 UDF (2.5 is supported in 2.6.25+ I think, but I had a backed up BE-R I had done at work with 25 gigs of films in rar'd avi format in UDF 2.60), mount and playing without copying off the disc or decompressing.

Going to try and get cross compiling going either tonight or some point over the weekend. Also want to get bluez going and try and get the bluetooth remote working with mplayer.

Yep, the Cell from what I can tell has 2 PPU cores, and 6 available SPUs. Supports Altivec - but still no where near playing MKVs. (it only uses 1 core of the PPU, or 1 PPU plus an SPU if you use spu-medialib).

Incase anyone is interested:-
http://video.google.com/videoplay?docid=-2732599907593842752&hl=en
http://video.google.com/videoplay?docid=442014928947824107&hl=en

That was when I started about a week ago with yellowdog 6. Will update sometime over the weekend.
 
Associate
Joined
18 Oct 2002
Posts
249
Location
Glasgow
....
Set all my HD's to 5 min spindown timeout, with them spinning the machine idles at 100W-ish, and although I've not measured yet, I'd assume that turning 4 10-15W HD's off will make a big reduction in power, as well as taking it one step closer to silence.

what did you use to do this? this is something i would like to do to get my power down. i have 2 Sata drives as storage
 
Soldato
Joined
9 Apr 2008
Posts
19,697
Location
Bedford
Recently iv used it to completally delete my pc :mad: (i was drunk and trying to set it up for a new gentoo install and proved my reading skills have fallen apart since school).

Since then iv been using to try out cedega again (and noticing they've taken away the old vesions page making it hard to get gentoo to install it aka test ubuntu again). Its fun and very unproductive :D
 
Man of Honour
Joined
30 Jun 2005
Posts
9,515
Location
London Town!
Wrote a replacement for the old tripwire script, essentially it hashes everything on the box and stores the values, runs every 12 hours, emails me with any files which have changed in any way or are missing or new. Maybe somebody could compromise the box, but they probably couldn't do so without me knowing...
 

Una

Una

Associate
Joined
26 Nov 2004
Posts
2,471
Location
Reading / Lake District
Wrote a replacement for the old tripwire script, essentially it hashes everything on the box and stores the values, runs every 12 hours, emails me with any files which have changed in any way or are missing or new. Maybe somebody could compromise the box, but they probably couldn't do so without me knowing...

What have you done to maintain the integrity of the tripwire hash (database?). Whats to stop the attacker modifying that, replacing it with the original values? :p
 
Man of Honour
Joined
30 Jun 2005
Posts
9,515
Location
London Town!
What have you done to maintain the integrity of the tripwire hash (database?). Whats to stop the attacker modifying that, replacing it with the original values? :p

Presently I'm getting another box to log in and run the script, then grab the hash database and store it locally, so you'd have to compromise the public facing box and the auditing box (which is a one way trust, the audit box can log onto the public box but not the other way round, it's also privately addressed with no external route in)

The only other check is to verify that atime on the stored hash matches the last time the script was run, which isn't a brilliant check I know but I left it in anyway...
 
Associate
Joined
21 May 2007
Posts
1,464
Just don't set it too short.....if you do, it'll be spinning up and down and up and down, every time your working with it.

Does WONDERS on IDE drives too, barely works on Serial (as most of it's functions do not apply).
 
Associate
Joined
21 May 2007
Posts
1,464
My / drive never gets any sleep, but the other two spend most of their time offline, the upside of that is that the spinning one keeps the other two warm(er), so their lubricants etc are all closer to optimum temp while spinning up, which probably reduces stress vs a total cold boot.
 
Back
Top Bottom