/gallery

An experiment in Vertical Hydroponics

12 Jun, 2011
0 Comments

So,
Some time ago I found a video about Hydroponic systems again, this time it was about small-scale "for window" installations of horizontal sets of pipes, with a tank, regulator and pump system. This got me thinking about space and my balcony, and I started researching into Horizontal systems, rather than vertical.

There's a few out there, most are really rudimentary (plastic bottles) or rather large scale, but I didn't find much documenting if they work or not, and how well they work and not. So I set a budget, and started to plan the project proper.

First my idea was to use a single, 2m tall, 100mm diameter PVC pipe, and drill holes into it, inserting small pots for the plants. After checking the basic math that told me that I'd have approximately 160 litres of volume in such a pipe, along with how much work I'd have to be doing to cut the holes, I went another route.

A bit more expensive route, with Y-shaped 75mm pipes ( and 45mm outliers) of gray PVC. I bought nine of those, and a 1m long 75mm pipe, to go with that, I got a barrel (60 litres) and a lid.

In the bottom of the barrel, I put some thoroughly cleaned ( and boiled) stones, in order to make it a bit heavier.

For the water flow, I went with a very simple pentry-pump for boats/freshwater tanks (7.5 litres/minute, 12Volt, 2 ampere, meaning around 24watt).

Filling: I used a mix of Leca ( for the main pipe) and Perlite (for the small outliers). From the beginning I was going to use coconut shreds, but I couldn't find any locally, so Leca it was.

Note here, that the Leca I got I had to rinse quite a few times in order to get the dust off. Much of it was quite messy, and would have killed my little pump in no-time. I'm still not sure how long that pump will live, but that is something for the future to tell.

So, after fitting the hole of the 1m pipe into the lid, I sealed it with silicone (for aquarium use, not wetroom use. )

In the bottom of the pipe, I cut a few openings in order to let water flow through. It turns out that these were not wide enough in practice, and when I turned on the pump, water would fill the pipe up to the middle, and overflow. This was solved by taking the whole thing apart, pulling it up and drilling holes into the bottom pipe to let more water through. Not a fun thing, and no pictures were taken then, as I was already getting very wet.

The water flow turned out to be too much anyhow (7.5 litres/minute is a lot, it turns out) so instead of driving it at 12V, I'm running it at 5-7 volts of power, causing a much more manageable water flow. Also, it turns out that the layer of perlite I was using for the small pipes flowed down into the main pipe, expanded in the water, and made water throughput low enough that I had water running everywhere when I was pumping full speed.

Right now, the hose from the bottom to the top is fastened with rubber-bands and tape, I figure something more long term may be needed. I also added a cloth filter to the top to avoid too much junk to fall in there.

Currently, the system is running on a timer to stimulate ebb/flow control, but I have yet to figure out how to do it, so right now its 2 hours on, 1 off during the day, and 15 minutes on/ 2 off during the night. If this turns out to be wrong, well, shan't be too hard to fix.

Now? My seedlings aren't quite done yet, so I have a hard time planting anything in this, until then, I'll have to see how this goes. The plan is to use easy herbs/salad this year, and maybe strawberries in the future.

Oh. And I need to get PH Measurements as well. yey.

Some hacking blogging

15 Feb, 2011
0 Comments

So, Due to Buerocrazy, life is sorta miffly atm.

However, I need to clear my head from that. At work I've recently been reading PCI and credit-card specifications, dealing with osCommerce, Virtual items for sale, generating tickets for a PoS system and so on.

It now appears the pieces are coming together, tickets can be bought, printed, ordered and added, and disappear from the inventory when things are sold out. Yey.

Next up, design and featurism. Then it's off to the other projects in order to see what happens with them.

I'm still looking for suggestions on hardware ( x86 or Arm, 24+ Megs of RAM, 32+ Megs of flash, Ethernet, 2x USB ( and maybe a built-in 3G modem) Theres a few on my list, but I want stuff for smaller batches, (a couple of hundreds) at decent price. There's a few on the market, but maybe you know of one that I don't know. Do tell!

Tomorrow, building more firmware, doing some cabling and design-work. Yey. Still waiting for some more prototype units of various CPU-denominations. I wonder what I can do with 32Megs of RAM, 200 MHz and 4 Megs of flash .. The flash will be a pita for my usecase, I fear. :/

Hardware, mdadm, raid, recovery

01 Jan, 2011
0 Comments

Spent over 48 hours trying to recover a drive to a machine which lost power during startup, causing the head to hit platters and corrupting sectors vital to bootup. Ouch.
Then we lost power during recovery.
However, all user-data was recovered in the end, backups are now in place, and things appear to be stabilizing. I just wish there was enough cash to throw at the problem to fix it properly. New drives + UPS would be necessary it seems. And we don't like that.

As for my home systems, 1 drive is failing ( sector reassigning failed ) and going back to the store next week. Fortunately it's 1 disk of a raid mirror, so it should be fine to recover.

The other set of raid5 is currently being shrunk (filesystem) in preparation of using mdadm to transform my raid5 to a raid1, in order to remove some drives from the chassi. Takes time, but should be lossless. Only reason for doing this is really to move hardware around, No faults so far.

Good news, USB stick and GNU ddrescue is the winner. dd_rescue is to be avoided. Bad news, ntfs-3g handles _badly_ with disk images, and consumes a _ton_ of cpu. Do not even attempt to use it.

gparted will do some interesting things when resizing partitions, for example, read only moves of data. Will take 12+ hours to operate. Make sure you don't lose power.

Networking issues, A Luxury problem

06 Dec, 2010
0 Comments

Preface:
So, with the new year approaching I’m also joining the future when it comes to fiber to the home networking. Well really, my subscription with the other ISP was coming to an end, and it was time to upgrade to something that was both cheaper and faster.

With the new ISP, I’m finally getting out of the “only one IP per customer”, and into a more realistic setup. This allows me to finally get rid of the NAT box and all the problems it entails .( Instant messenger, UPnP and various protocols still do not act well with NAT. And probably never will )

However, you don’t get any amount of IP-addresses, so there has to be some limit, and for things like the wifi, I do not see a good reason to bridge anyone into the ISP network without some sanity checking.

Now, I wouldn’t be a proper geek if that was the only thing on my requirements. See, I also want to maintain good speed with my NAS storage, ( nfs + samba ) which unfortunately my router cannot manage ( only 100Mbit, while my switch is Gigabit ). However, lets be serious, this is a minor issue.

Add to this that I have, quite a number of various devices speaking ethernet ( Embedded systems galore, 10-15 ‘computers’ around here ), so we can’t really just assume that I’ll get enough public IP’s for all of them.

So, what I’d _REALLY_ want is a server on my home router (OpenWRT 10.03.1-rcX Backfire based) that would set up a private LAN for most machines, but for a few select MAC-addresses would instead of allocating a private IP, do a DHCP proxy call and allocate a public IP-address for those.

Preferrably the DHCP-proxy would then re-write certain fields like “default route” ( the router ) DNS ( Well, doh ) as well as update the DNS-entries for the internal lookup so you could use consistent for your own machines. ( MAC-based to start with )

Well. Right now, there is no such software, and for this weekend I didn’t have the urge to even try and scope it up, much less create it.

So, That leaves me with two “obvious” solutions.
*) DHCP Proxy (dhrelay from ISC and dhcp-forwarder)
*) Transparent Bridging

For these to work I had to do some magic in either way. First and foremost, set up VLAN’s on the internal switch of my WRT160nl. There I’d dedicate 1 port to be “outbound” ( and hook a switch to that) and the remaining 3 to be “local net only”.

Figuring this out took me a bit longer than I’d thought, as I managed to lock myself out by the ways of firewalling whenever I attempted it, causing quite a few reboots into safe mode while I was attempting in blind to figure out what worked and what didn’t. Below will be some documentation on how to get this just right (tm)

Also note that the default documentation on setting up VLAN on the OpenWRT page is broken, as it will create RFC-noncomformant tagged VLAN’s . VLAN 1 is not supposed to be tagged, see 802.1D standard.

So, the relevant parts of /etc/config/network :
config ‘switch’
option ‘name’ ‘eth0‘
option ‘reset’ ‘1‘
option ‘enable_vlan’ ‘1‘
option ‘enable’ ‘1‘

config ‘switch_vlan’ ‘eth0_0‘
option ‘vlan’ ‘0‘
option ‘device’ ‘eth0‘
option ‘ports’ ‘0u 1u 2u 4* 5*’

config ‘switch_vlan’ ‘eth0_10‘
option ‘vlan’ ‘10‘
option ‘device’ ‘eth0‘
option ‘ports’ ‘3u 4t 5t’

config ‘interface’ ‘vlan0‘
option ‘proto’ ‘static’
option ‘ifname’ ‘eth0.0‘
option ‘ipaddr’ ‘172.27.1.1‘
option ‘netmask’ ‘255.255.255.0‘
option ‘defaultroute’ ‘0‘
option ‘peerdns’ ‘0‘

This first turns on VLAN and the switch on eth0.

the part that reads : 0u 1u 2u 4* 5* has a magic meaning. It means that vlan 0 will be _untagged_ as it leaves ports 0 1 and 2, and _tagged_ if an untagged packet LEAVES port 4 and 5. It also makes this the _default_ vlan.

the part that reads “3u 4t 5t” is similarly magic. it means that packets leaving port 3 shall be untagged if they were tagged with vlan 10. 4t 5t also means they get tagged going out of the two internal ports. However, it’s uncertain if this actually does anything.

Next, we assign a local, static IP-address to the vlan0, and serve DHCP off that as normal. That means that physical port 3 on the switch is now magic, and assigned to vlan10 ( eth0.10 ) and free to perform experiments on.

Also note, you _NEED_ to add vlan0 to the /etc/config/firewall zone for your lan. (replace eth0 with “eth0 vlan0“ and do similar in your /etc/config/dhcp

So, My first few hours was spent digging through how to do this without bridging, so I spent many hours getting dnsmasq not to bind the external interface nor the eth0.10 interface, and attempting to get dhcp-forwarder or dhcrelay to work. Unfortunately I got neither to work with my ISP (Telia). However, this may work in the future? I wouldn’t know. I still haven’t compiled up dhcp-helper from the same guy who creates dnsmasq

So. After some time I scrapped this position, and decided that it would be simpler to create a bridged interface between eth1 (external, WAN) and eth0.10 (internal, VLAN 10, port 3 on the switch ) said and done. It was actually quite simple.

from /etc/config/network:
config ‘interface’ ‘wan’
option ‘peerdns’ ‘0'
option ‘type’ ‘bridge’
option ‘ifname’ ‘eth1 eth0.10'
option ‘proto’ ‘dhcp’
option ‘auto’ ‘1'

And that about solves it.

Now, I can hook my swtich to that port, and the machines on this side also get nice external IP addresses.
There’s just one snag. I do not get any firewall anymore. For cited performance reasons, ( I’m unable to find numbers anywhere ) the bridged filtering is disabled in the OpenWRT Backfire kernels. This does put a hinder to my plans, as I’m unable to actually perform what I wanted to do here.

Also, performance stinks right now. Why? My ISP has proxy-arp. This means, that their gateway is responding to _ALL_ arp requests for any IP-address in their range as belonging to them. This in turn is enough to make my gigabit switch scratch it’s head, and forward packets through my bridge and up into the ISP, and then back again. Effectively degrading my gigabit ethernet into 100Mbit or less.

This would ofc. be easy to stop by blocking arp-requests at the firewall. Except that the firewall isn’t enabled on bridged interfaces.

So, for the future:
a) Check out the performance of a custom kernel with bridging. Does it kill the upstream?
b) Investigate in dhcp-helper.
c) Look at creating a patch for dnsmasq that does custom proxying of DHCP based on certain mac-addresses.
d) Kill everyone, NAT and just go with ipv6 whenever it arrives?

Computer issues

23 Jun, 2010
0 Comments

So, over the last couple of days I've had some more and more interesting errors on my computer.

Symptoms: Hang in bios, after CPU detect, writing "Memor" and then hanging.
Symptoms happen in situations of: Computer been off for 10+ hours, just rebooted, powercycled, pulled cord for a few minutes. No real pattern there. And then sometimes it comes up again and just works.
Tried to remove the RAM, move in one piece at the time to different slots. Still bugs out.
Tried resetting BIOS, Still hangs at times.
Tried reflashing the BIOS. Still hangs at times.

So now I'm sitting here scratching my head without a friggin' clue on what to do. New mainboard, it would seem. Which is unfortunate, because I rather like my current one ( Gigabyte, GA-P35-DS4 ). So, Now I'm looking for recommendations on a new mainboard.

Requirements: Onboard LAN, Audio, Firewire, USB, 6x or more SATA-ports.
Requirements: socket 775 4x RAM slots, DDR2.
Preferrably something that has more space between the RAM slots so I could run my current ones at full speed rather than have them overheat horribly due to being nested too close.

I'm not a fan of SLI, so that's no real necessity (meaning I could just as well go for P43 as P45 ) and since it's a somewhat older Core2 duo ( 6600@2.40GHz) and I'm not _that_ inclined to getting new RAM/Mainboard/CPU at this time (well wonder?)

Just one of Those Days

28 Jun, 2008
0 Comments

Okay,  Crappy morning due to a slight hangover after a rather unsatisfying evening out. Just one of those duds that happen, noones fault, really, and it wasn't as if anyone was really in the mood.  Finding out the club had gone severely downhill from what you remember a few years ago,  and all of it just adding up to blanket the whole in a miserable feeling.

But, a new day.  A hyperactive spid who wants to get Stuff Done!   Well,  there I am, goofing around and trying out the freshly installed Max Payne 2 in Wine, getting the thing working was a breeze, except for the intermediate audio issue I was going into, when the thing hangs. Hard.

A few moments of WTF and I reach for the magic key combo,  finding it does nothing (no, not Ctrl alt delete. Alt SysRQ SUB )

And then it starts booting. And hangs.

Great.  The computer is no longer recognizing my RAM.   It's stuck,  Num lock not blinking. No nothing.

A long time of frustration later and I leave the computer "hung" to go check on something, and come back to a system halfway though the boot process.  Some more expermineting shows that it does indeed recognize the RAM. But not very quickly.  We're talking of a 5 minute hang in BIOS, Which is something that I find unacceptable.

Some more fiddling shows the same behaviour on all memory banks, No matter how many chips are in or not.   Sigh,   I suspect the Mainboard, but I can't be sure.  Unplugging the chips and hooking them into a friends computer confirms it. They boot perfectly and instantly.

I get home a couple of hours later ( Cookies and Metroid is a great way to spend some annoyance ) and hook it up.

The computer boots instantly and perfectly.

ARGH!

A.H.S. A.S.S.

29 Aug, 2007
1 Comment

Repeat after me. All Hardware Sucks. All Software Sucks.

The hard drive on one of my two desktop machines just went Chaaa-cachunk chaaa-cachunk, Chaaa-cachunk. Since its IDE it takes the other drive on the same cable down with it, not yet sure which of the drives it is, but one of the two that's on ide0 is certain, since the machine won't recognize either of them or get me into a boot loader.

Most things are backed up, but I'm not sure on the backup coverage.

No, I am Not happy.

Cheer me up, will yah?

Annoyed

30 May, 2007
1 Comment

Okay, Got the computer shut down neatly. Poweroff, Dismantle, unhook drives, label them. Unhook PSU, unplug cards and stash in bags. Remove Mainboard and stash.

Start cleaning the case out from the dust, then insert new mainboard, screw it in (mistake, should have checked the CPU cooler first, needs additional fastenings there) .... and then I see. RAM. Unlike what I had thought it wouldn't fit. Meh, silly me. I really should have checked if the RAM I had would fit before ordering. Eff.

Now I had to find an old case and scavern the computer up into working, It does so, somewhat, right now. Great :/

Next goal, working on a Gentoo based small system for a Via C3 cpu, needs to fit in 128 Mb and I really dont fancy using ulibc and similar tools, so I guess it will take some hacking. My guess is that I need to setup a CHOST Chroot on the Dell machine first, and from that go on and build a targetted system for the C3 (it lacks the cmov instruction for one)

 1