Tuesday, August 10, 2010
Socialization
I saw this rerun of a Peanuts cartoon and it reminded me of this blog: No Thank You, We Don't Believe in Socialization! The author points out a perspective not many have considered on the way "socialization" is "implemented" in the current public schools. The old "one room schools" seem to us outmoded but maybe they had more to offer than meets the eye.
Friday, August 6, 2010
Milano gets yet another super
I ran home and added a honey super to Milano at lunch. Wow! This was a newly installed package - mid April - and they are doing terrific! They were packed in there. Harvested a bit of honey comb too and we all sampled it. I can't understand why it is so much better than the stuff from the grocery - but it is! I love these bees! They are so nice! I popped the top and pulled a frame and scraped out some comb and no one got angry. None of them tried to sting me or follow me. Wow! It'll be a long time before I ever buy any non-Italian packages again!
Wednesday, August 4, 2010
Perl and SQLite
Finally got around to finishing my little SQLite and Perl program. To speed things up, I used a shell script with remote SSH commands to grab the data, then used Perl to stuff it into SQLite. Very cool! Need to use Perl's Net-SNMP on next version but this was mainly an excuse to use SQLite. Glad I did. There's a lot of strangeness - can't get used to putting a dot in front of commands and many of my favorite SQL commands are missing or renamed. Still - SO COOL to be able to create a database on the fly like that.
Want to delete all tables in SQLite?
You can do it with the following DANGEROUS commands:
PRAGMA writable_schema = 1;
delete from sqlite_master where type = 'table';
PRAGMA writable_schema = 0;
you then want to recover the deleted space withVACUUM
and a good test to make sure everything is okPRAGMA INTEGRITY_CHECK; Found this on the Internet but haven't ran across it elsewhere.
Saturday, July 10, 2010
Whatever happened to DSL?
I really love(d) DSL. But it's coming up on 2 years since the last release - I was getting worried, so I started searching for answers. Funny how this all dried up right after the book was published. It looks like in fighting took it's toll on the project. The good news is the is an even cooler tiny Linux distro now: Tiny Core Linux. This thing is TINY! It boots a Linux 2.6 kernel and runs X in under 10MB!! Watch this flash demo! I burned the image to a CD and booted my favorite obsolete notebook - it ran great! I'm looking forward to installing this on some old junkers I've got around here to see how much more functional they become. It has some similarities with DSL since it is the pet project of Robert Shingledecker, one of the main developers of DSL and authors of the DSL book. Because of that, I expect the stability to be pretty good and package management to be pretty similar. Besides, looks like he's been refining this for quite some time while I waited for the next DSL iso to show up at the DSL website.
Old hive, new hive
My large healthy Russian hybrid hive that wintered well then went queenless did not make it - sort of. Let me explain. After the "shaking" and new queen didn't take, I tried one more queen. It still didn't make it. However, the Italian hive completely filled the first brood chamber shortly there after WITHOUT HAVING RAISED ANY BROOD. Obviously, the left over workers moved into the new hive instead. I'm already on my 3rd hive body, getting ready to add a 4th! They even went back and robbed ALL of the food stores from the old hive, cleaning it out completely. (I didn't really know what else to do with it, it was mostly tracked up brood chambers and I didn't want the honey myself). So, next year, I guess I'll be buying another package or two. I'd like to get 3 hives going so some day I could repair my own problems by robbing a brood frame from one and giving to another. Anyway, I'm hoping for a good honey season. Looks like we're off to a good start.
Friday, June 11, 2010
More Fun With ZFS
How to migrate a message store on a ZFS filesystem? I was told "Simple! Just create a snapshot, zfs send to other filesystem, then create a new snapshot, then shutdown app, and send snapshot to new file system with minimal downtime."
Sounded pretty simple, so I tried it. Like earlier attempts to "zfs send | zfs recv"... several minutes go by and NOTHING HAPPENS. The delay made me nervous (not knowing what was going on) so I aborted it from the NON-test system (sending to this remote system) and used tape to get it over there.
Now I am testing with about 20% of the actual message store so whatever the numbers are here, it will be safe to assume 5x longer on the other system. I start the move:
It did NOTHING on the actual file system for 20 minutes. Meanwhile,
"zfs list" showed that it created the target filesystem and the target
filesystem usage was growing. When the target filesystem size matched the original filesystem, the data seemed to ALL SUDDENLY APPEAR ON THE DISK. I didn't trust it so I ran du and sure enough - 10's of thousands of user accounts were there. Pretty wild. Next test - 2nd snapshot. The 2nd snapshot should be ONLY the diffs and should be pretty quick. I guess the assumption is that there are no other snapshots. It has to be clean. Interesting.
This means I could use the daily snapshot - once done, move to the
new disk, take system down, take a 2nd snapshot, move the difs & ta-dah! Very cool stuff, this ZFS. Then I try part two.
A few minutes later - TA-DAHHH! It is done. It took 23 minutes (the first time it took 20-21 minutes). Weird. I don't see the point of the 2nd snapshot - just stop and snapshot the first time - or, I've done something wrong (most likely).
Oh well. Fun experiment. But I'd better do some more reading before trying this live. Incidentally, this Solaris 10 ZFS Essentials
is really nice for those times you're away from a PC and want to read about ZFS. I haven't seen the new Solaris ZFS Administration Guide
but I'm putting it on my list of books to acquire.
Hopefully, this was useful or at least entertaining. I know, I know! "RTFM!" (Which stands for Read the Fine Manual, of course).
Sounded pretty simple, so I tried it. Like earlier attempts to "zfs send | zfs recv"... several minutes go by and NOTHING HAPPENS. The delay made me nervous (not knowing what was going on) so I aborted it from the NON-test system (sending to this remote system) and used tape to get it over there.
Now I am testing with about 20% of the actual message store so whatever the numbers are here, it will be safe to assume 5x longer on the other system. I start the move:
zfs send store@today | zfs recv newmail/store
It did NOTHING on the actual file system for 20 minutes. Meanwhile,
"zfs list" showed that it created the target filesystem and the target
filesystem usage was growing. When the target filesystem size matched the original filesystem, the data seemed to ALL SUDDENLY APPEAR ON THE DISK. I didn't trust it so I ran du and sure enough - 10's of thousands of user accounts were there. Pretty wild. Next test - 2nd snapshot. The 2nd snapshot should be ONLY the diffs and should be pretty quick. I guess the assumption is that there are no other snapshots. It has to be clean. Interesting.
This means I could use the daily snapshot - once done, move to the
new disk, take system down, take a 2nd snapshot, move the difs & ta-dah! Very cool stuff, this ZFS. Then I try part two.
bash-3.00# date && zfs send store@L8R | zfs recv newmail/store && dateHuh?! It sounds like I have to destroy the content on the new system to do this. This can't be right - or can it? It's a test system so I proceed.
Friday, June 11, 2010 10:55:49 AM CDT
cannot receive new filesystem stream: destination 'newmail/store' exists
must specify -F to overwrite it
bash-3.00# date && zfs send store@L8R | zfs recv -F newmail/store && dateOh yeah, I forgot, it duplicates the snapshot when you do this. No harm to get rid of that I suppose...
Friday, June 11, 2010 11:23:23 AM CDT
cannot receive new filesystem stream: destination has snapshots (eg. newmail/store@today) must destroy them to overwrite it
bash-3.00# zfs listThere! Now check to see that its all gone and note the filesystem sizes.
NAME USED AVAIL REFER MOUNTPOINT
newmail 41.4G 226G 44.0K /newmail
newmail/store 41.4G 226G 41.2G /newmail/store
newmail/store@today 187M - 41.2G -
store 41.4G 292G 41.2G /store
store@today 78.0K - 41.0G -
store@L8R 193M - 41.2G -
bash-3.00# zfs destroy newmail/store@today
bash-3.00# zfs listAfter a bit and while it's doing this, I switch over to another console and run zfs list:
NAME USED AVAIL REFER MOUNTPOINT
newmail 41.2G 226G 44.0K /newmail
newmail/store 41.2G 226G 41.2G /newmail/store
store 41.4G 292G 41.2G /store
store@today 78.0K - 41.0G -
store@L8R 193M - 41.2G -
bash-3.00# date && zfs send store@L8R | zfs recv -F newmail/store && date
Friday, June 11, 2010 11:23:57 AM CDT
bash-3.00# zfs listHey! That's exciting! It did EXACTLY as I thought - it destroyed the new filesystem I created. What was once 41G is now 78k. ;-( But hang on, let's see what we end up with. Some time later...
NAME USED AVAIL REFER MOUNTPOINT
newmail 4.39G 263G 44.0K /newmail
newmail/store 4.39G 263G 4.39G /newmail/store
store 41.4G 292G 41.2G /store
store@today 78.0K - 41.0G -
store@L8R 193M - 41.2G -
bash-3.00# zfs list && date7GB?! I only added about 200MB to the original so this is interesting ... Wait a bit more ...
NAME USED AVAIL REFER MOUNTPOINT
newmail 7.02G 260G 44.0K /newmail
newmail/store 7.02G 260G 7.02G /newmail/store
store 41.4G 292G 41.2G /store
store@today 78.0K - 41.0G -
store@L8R 193M - 41.2G -
Friday, June 11, 2010 11:29:47 AM CDT
bash-3.00# zfs list && dateOkay - that is WAY bigger than the snapshot. Interesting... Wait a bit more ...
NAME USED AVAIL REFER MOUNTPOINT
newmail 18.1G 249G 44.0K /newmail
newmail/store 18.1G 249G 18.1G /newmail/store
store 41.4G 292G 41.2G /store
store@today 78.0K - 41.0G -
store@L8R 193M - 41.2G -
Friday, June 11, 2010 11:35:15 AM CDT
bash-3.00# zfs list && dateOkay, it is definitely going to recreate the entire 41GB and (hopefully) include the extra stuff I added. Exactly what I expected BUT I'll take it.
NAME USED AVAIL REFER MOUNTPOINT
newmail 38.4G 229G 44.0K /newmail
newmail/store 38.4G 229G 38.4G /newmail/store
store 41.4G 292G 41.2G /store
store@today 78.0K - 41.0G -
store@L8R 193M - 41.2G -
Friday, June 11, 2010 11:44:58 AM CDT
A few minutes later - TA-DAHHH! It is done. It took 23 minutes (the first time it took 20-21 minutes). Weird. I don't see the point of the 2nd snapshot - just stop and snapshot the first time - or, I've done something wrong (most likely).
Oh well. Fun experiment. But I'd better do some more reading before trying this live. Incidentally, this Solaris 10 ZFS Essentials
Hopefully, this was useful or at least entertaining. I know, I know! "RTFM!" (Which stands for Read the Fine Manual, of course).
Subscribe to:
Posts (Atom)


