Convex hull, and not the northern town either

I spent the bulk of the day working with collision meshes. Which isn’t the most exciting thing on the planet, especially when you have to decode it from an XML file. Also rather annoyed that the debug rendering doesn’t really support it. So you end up making a convex hull shape from a convex hull. Anyway, worked in the end. Sorted out centre of gravity problems and now have other ones.

Walked the dog, it’s bloody freezing.

Went to combat, that was tiring.

Did a bit more Japanese, I can now turn verbs into the past tense.

TP Link modem / router thing arrived. I’ve connected it up in bridge mode so works the same as the Draytek as far as pfSense is concerned. No problems so far, seems to grab pppoe with out any fuss. It was reluctant to connect to the web interface after connection, but a reboot of pfSense appears to have sorted this. Anyway, will monitor it’s performance. I’ve a new faceplate turning up tomorrow so will see if that makes any difference.

A different brand of paint stripper also turned up. So pasted a bit of that on to check it’s performance.

Supposed to be back to running tomorrow, if it stays above freezing.

Zen and the art of packet loss

Started a bit late. Wanted to do research into collision meshes. Bit of a messy day as far as that went. Spent a while peeing about trying to get an Orange sim car to work. Failed, ordered another Vodafone one. It’s only to test to see if a phone is properly unlocked anyway. Then the whole internet was just grinding to an absolute halt. Looking on pfSense, surprisingly it wasn’t Virgin, it was Zen. It was showing around 50% packet loss. This was somewhat odd. Got hold of Zen using online chat in about 10 seconds. They asked to ping my router, which of course then required me to piddle about with pfSense adding a rule for ICMP and route through to the WAN address. Anyway, got there without out two many problems. So he pinged me from Zen…trace route was all good until it got to the final hop, which was me. So he asked if I had an ordinary router, which of course I’ve got boxes of. So I decided the closest one was the Draytek I use as an access point. So connected that to the DSL line. It synced no problem. But ping wasn’t enabled. Now with this being just used as an AP I’d disabled DHCP on it. So it was guess the IP address time. I failed. So up to the loft for another router. Got another Draytek. This one synced. Also didn’t have ping enabled, but at least it did have DHCP on it, so was easily sorted, after I remembered the admin password. So he pinged this one, 100% good. Ok, so either pfSense was up the swanny or pfSense was up the swanny. So reset it. Worked fine for about two minutes then packet loss again. So I decided to look at the web interface for the Vigor 120, which is the ethernet modem. Took bloody ages trying to connect to it and then it kept timing out. This was very odd. It must have died. So prodded it a bit. Found a tiny tiny reset hole and shoved a paperclip in it. It did a factory reset. Then synced and worked beautifully. I haven’t had a packet loss since. Moral of the story, if it doesn’t work try resetting it…yes indeed, sometimes this does in fact work.

Walked the dog. Went to the gym and did Pump. Bath and wine o’clock me thinks. Not sure what’s happening this weekend, but it will no doubt be busy. This cold has now lasted for three weeks.

Mostly I stayed in bed and read a book

So today I didn’t exactly do much. I woke up, had breakfast in the middle of the afternoon, stayed in bed and read a guide book to Japan. It was a very relaxing morning/afternoon. I then did the dog shit run, stocked up the bird table and had some toast.

Finally got round to doing the pfSense upgrade, which is now almost completed, just need to reinstall and set up NUT. Upgraded the server packages, upgraded wordpress and al it’s packages. Upgraded my Ubuntu box. Stuck a bit more filler around the boiler flu. That needs to be sanded now really to see what a full bloody mess I’ve made of it. Ordered some pastry rolling sheet things. Ordered some more wine kits. The strawberry is cleared ready for bottling, so I’ll probably do that when I start the new ones off so I can sterilise all the stuff together.

Then we went out for a meal. Chose a different place from TripAdvisor. An Italian called ‘Di Meo’, which is at the top of Gloucester Road. Looks a bit of a tip from the outside, but a lovely little restaurant. TripAdvisor review done. Here’s my review of the “Lucky Dragon”. Then came back, got into bed again and did some more reading. Think it must be time for a bath, before, mmm, bed I guess.

I can feel a summons coming on

Still working on the mobile game. Spent most of the day trying to register an iPhone5 on test flight, it kept telling me it was an iPhone4. Eventually found out that it was because it was restored from a backup. So lots of buggering about later it decided it was in fact an iPhone5. So first version of that concept out, got some feedback, lots of work to do. I’ll start on that tomorrow. Ended up doing a few bits on the main project, again need to do a bit more on that tomorrow.

Went out for a run. Much to the dogs annoyance. She got her walk in the evening, plus we played ‘bombing the ball down the stairs’, which is always popular and knackers her out after ten minutes.

Still no receipt from plumbers. So Saturday I’ll put a formal request for everything in a letter and send that off. If after fourteen days they fail to respond I’ll send one recorded and then issue a summons. I don’t know why people attempt to piss me off, they all fail.

The Strawberry wine is almost there. Added a couple more sachets of something, now need to let it clear, then siphon it off. Then add something else, bottle it and wait another bloody four weeks. The White wine still seems to taste a bit shit to me.

New flash card arrived and USB reader, I shoved it in the Ubuntu box and it read it fine. So now transferring the latest pfSense image to it, will then try and mount it and copy the config across. Then at the weekend I’ll put the new card in and see what it does. I’m not going to bother putting gag on it this time as that seems to interfere with the automatic upgrade process. I’ll wait until I have a stable image before doing that again. I never updated the MAC address for the network card on the UPS script anyway. They are pretty low power now so the UPS can run for them for quite a while, so I’m not going to worry about it for the moment.

Need to pick Jamie up from the station at midnight. Oh joy.

I may get to sue someone else soon, good I was getting bored

Still working on the mobile project I was working on, but I’m working on it on PC as it’s just easier to work with. I’ve now got it to a stage though where I can transfer it all across to the Mac and XCode and build it for iOS. Then I can start debugging it on the iPhone and iPad. It’s only a concept demo, but these things have to start somewhere.

It was raining so I worked right through lunch and didn’t end up going for a run until about 5PM. Jamie did actually get up this morning to get his haircut, came back with a floppy fringe (yey!), decided he didn’t like it so gelled the fuck out of it (boo!). Shame, it shows off his massive forehead. But the good news is that Google are interested in using it for ad space.

Came back and did some more work. Still haven’t managed to kill new plants yet. Left another message for the boiler fitters to say I still haven’t received a proper VAT invoice yet and that they haven’t filed the correct paperwork at the council and Bosch have no registration of the boiler serial number. I’ll give them until the end of the week then I’ll put it in writing. Then I’ll give them two weeks and then issue a court summons for the entire amount plus costs. I really wish people wouldn’t fuck with me as I am a real nasty bastard. Incidentally Paul Hayes never filed the correct paper work at the council either, so I’ll be after him as well…

Checked on the Strawberry wine, the gravity on that has finally dropped so I’ve added the stabilizer. That’ll need to settle for a couple of days.

Jamie is now packing as he’s off to Euro-Disney tomorrow with another poof from work. At least that means I get an evening of peace and can go to bed without being kept up by the ‘night-light’ of his bloody phone.

I’m attempting to upgrade pfSense again. Remember last time it managed to upgrade itself to itself, which wasn’t exactly what was planned.

I think I’ll do the dished then have a shower. Oh the pfSense box has just reset itself, lets see what a cock up it’s made this time. Oh, the same cock up as last time. Lovely, I’ll try a manual update.

And then the Chinese buffet occurred

Started off the day with breakfast, coffee and watching porn. This thankfully lead to sex. I tried a number of adventurous positions, my knee is still aching.

Got up. Removed large amounts of expanding foam from the boiler flu using a bread knife. Stuffed hole with deep gap filler, which has a half hour drying time, which means now at bed time it’s of course still squidgy. Serialised a few more bottles and bottled the rest of the wine. We took the dog out on her new 10M leash thing. Took her to a field and chucked a ball about, unfortunately I chucked the ball 11M, my wrist is now swollen. Did in the end attached the 10M leash to her 8M extending lead, Jamie being a gay, couldn’t actually throw the ball that far so removed the problem completely.

Came back, had a boiled egg.

Attempted to upgrade pfSense to the latest snapshot build. It completed the upgrade process and successfully upgraded to the exact same version which was on there before, so something got tanked somewhere in the process.

Then we went out to a Chinese buffet, ‘Lucky Dragon’ which a bunch of Tesco people, I ended up sitting next to Jason, so spent the evening making suggestive comments and admiring his completely ‘gaunt’ expression. There’s a man who needs to go on a burger diet. Meal was nice, but took ages, we started at 8, only just finished it at 11. Will write my TripAdvisor review shortly. So now back and writing things. Think I will have a bath, a glass of wine and then bed, as it’s now midnight.

Android atomics

So today I was looking at the atomic problem again which I spotted yesterday. I traced it in the end on the PC version, it was due to a unsigned int32 being shifted right 32 times, which I would have thought would have made it 0, on PC it doesn’t it seems to shift by the modulo of 32, so 33 would shift 1 etc. After 25 years I still get the odd annoying surprise. Then it was back on to Android, which has no 64 bit atomics. Found a nice big bug in my emulation for them which wasn’t locking the atomic properly. That’s now all working on Android but I want to play around with spinlocks a bit more as it’s a little bit thread happy.

Good news on the mobile game front, it’s been set as ‘ready to publish’, which means it’s been approved by Apple, the only thing stopping it from appearing on the app store is pressing a button and a large room full of lawyers. Wait until Friday then I’ll finally announce what it is.

Walked the dog, went to the gym. She’s off to doggy day care tomorrow. Cleaners coming tomorrow.

Then spent a bit of time pissing around with my favourite subject, pfSense. Jamie was trying to connect 360 to XBox live, of course it’s set to strict NAT. I did try and set it upo for UPNP, it managed to open one port and passed the tests but failed to work correctly. In the end I just set it up with it’s own IP address which worked, but I do really need to revisit it again at some point.

pfSense – NAT reflection

Didn’t sleep at all last night, didn’t help when Jamie decided not to go to bed until around 5AM and the dog was busy throwing up. Then the phone went, it was mother, ignored. Got up and spent the bulk of the very horrible day working, well testing the mobile game, I think that’s the last day on that now, back on Android tomorrow I think.

In between testing on iPod I was installing the new pfSense box. Pain in the ass part one. So the pfSense box has no drives, all it has is a compact flash card. So to install pfSense on to it is quite a challenge. So I installed Ubuntu desktop edition to a USB stick, using Ubuntu desktop edition, which is full of bugs as far as writing out an image is concerned. You select the image name in the file selector and then it ignores you and uses whatever it can find. Anyway after getting the bootable image the next thing to do is copy an uncompressed CF image of pfSense to the stick as well. Also copy over GAG boot loader as it doesn’t suffer the PXE boot problem to do with wake on LAN (look back a few months in the blog). So when you have your image, now plug stick into pfSense box and boot it, allow about ten minutes for it to boot. Struggle to find a bash shell, open it and then block copy over the pfSense image over to the CF card using linux DD command. Once that’s done, install GAG and run the install on the CF card, it will moan about GRUB needing installing but it’s already there. Remove stick and reboot. Hopefully you will get the GAG startup screen, add the pfSense partician to the loader and set the timeout to this partician. Once that’s done let the bloody thing boot. Hopefully all will be okay and you can assign the first couple of NIC’s to WAN and LAN. Once that’s done, take your old pfSense config XML file and do a search and replace for all the interfaces and replace all the bge0/re0 stuff with the correct interface assignments. Then restore that file over to the new pfSense box and reboot. Hopefully all will come up and be working, well it was for me….except one thing, there’s always the one bloody thing….

I couldn’t connect to my server on the DMZ from the LAN side, no matter what I did, it just wasn’t happening. It’s all to do with NAT reflection, basically if you try and connect to the web server from inside the LAN it has to send out a request from the LAN IP, via the gateway, out of the WAN interface, then back in the WAN interface, through NAT and then to the server, it then has to make the whole trip back. The only way I could get it to work was to use port forwarding for each of the ports on both server IP’s and then only worked if I used the proxy to do reflection, which basically runs a deamon to ram the packet request back down the same port it came from. This worked, but I wasn’t happy about it.

So went to the gym. Came back after thinking about it, a lot. So I added a firewall rule to log packets from the netbook, just to see where they were going. With the port forwarding and proxy reflection nothing showed up in the firewall log. So I disabled the port forward and I could see the request then going out to the WAN IP address and promptly getting lost in the either. So I enabled normal reflection on the 1:1 NAT, then on the log I could see the WAN IP being translated to the internal LAN IP….and getting lost somewhere in the internal LAN. So had to think about it…there was some guff in the advanced settings about reflection only working if the rules could determine the source interface on rule loading. So then, when the request is generated LAN side it then translates it to the LAN IP from the WAN IP via the NAT 1:1 translation, it then sends it via the gateway, which is the load balancing gateway, so it could potentially send it via either WAN1 or WAN2, then it really is going to have a bit of an issue trying to work out well the hell to reflect it to. So I added a rule to the LAN which was to send all packets destined for the internal LAN IP’s of the server via the default gateway. Bingo. That worked a treat, and thinking about it, it’s the correct solution. So now when a request is set from an internal LAN IP to a WAN IP on the server, it takes the source IP, looks at the destination as that’s a 1:! NAT mapping it translates it from the WAN IP to the internal LAN IP, it then sends that via the default gateway, which then goes through the default WAN (I’m not sure it actually ever gets that far as it really doesn’t need to), goes to sever, server then replies back via the default gateway and gets translated back to the correct IP. Job done. Hours of fun, for which I didn’t have hours for.

Mother sent an email, apparently her curtain rail has fallen down. Sorry, but during the week I have 24 hours in a day, excluding the ones I’m asleep for I still have 37 hours of stuff to cram in. Your curtain poll is not high on my to do list. I still have a load of home checks to do as well. The dog didn’t even get a walk today, as the only breaks I had it was absolutely pissing down. We did have a play with her ball though when I came back from the gym. But she’s off to doggy day care tomorrow, so that’ll make up for it. She’s actually been very good considering, I don’t think she was overly keen on venturing out anyway.

My drain cleaning attachment has turned up for my pressure washer.

Right, well hopefully that’s the last about pfSense now. Incidentally it uses around 17 watts considering the old box was around 85, so that’s a hell of a power saving. Also it’s performance appears to be very good, I was getting some pretty good speed tests results. Right, I’m now finished for the day, it’s twenty to one and I need to be up at 6 to take the dog to paw stretchers. Fun fun.

pfSense – the revenge

So started of this morning with one more tweak to the mobile game, not sure if it’s been submitted to Apple or not yet. Anyway, spent the rest of the day play testing it. No real significant issues that I could see. Thoroughly enjoyed playing it as well.

Decided to try this fasting diet thing, as the only change I had to make to my existing diet to get under the 600 calories was to remove the sausage roll from my salad and the two slices of bread from my lunchtime sandwich, and that was it.

Walked the dog, we did the wet route today as it wasn’t particularly nice.

Went to the gym and did combat. Came back and started to do battle with the new pfSense box. New box is built, this is this nice Jetway board with quad lan. The version of pfSense already on the flash card is the release version and that doesn’t appear to support the new network nics. So I’m now trying to get a version of the nano pfsense on to the flash card. This is turning out to be somewhat problematic. I don’t actually have a machine with a compact flash card interface on it, except for one linux box with one mounted as a sata drive and another one on the new Jetway board. So I’m now trying to install it off a USB flash drive. The good news is the new version does seem to support the NIC’s, the bad news is it won’t actually mount as a file system. So what I’ve done now is install a bootable version of Ubuntu on to the flash drive, I’ll then copy over the cf image to it and then try and write that to the flash card. I still then have to update the boot block as it will no doubt have the old issue with being unable to boot properly from the wake on lan. So lots of fun things to play with ahead.

Skyfall

Didn’t start at the crack of dawn, mainly as I don’t do that shit anyway and I didn’t finish until 3AM. And then when I finally got to bed, Jamie was as horny as hell and demanded his version of kinky sex, well it would be rude to not oblige.

So today was mainly about tidying up, finishing off and testing. So that’s exactly what I did. Last minute bug fixing and testing.

Took the dog out for a walk and for once it was a pleasure. I think she did actually learn something yesterday at doggy day care.

New motherboard for pfSense box has arrived. It’s still in the box, hopefully look at it the weekend. Went to gym, ran, not very exciting. Ate salad.

Then at ten to ten I went upstairs to Jamie and said ‘lets go then’, to a rather shocked Jamie, who had completely forgotten that I’d got tickets to the new James Bond film – Skyfall. M32 had a junction closed, so we were slightly late, the good point about this was we missed all the ad’s for Gordon’s Gin. We had the posh seats in the ‘Director’s Lounge’, if you are going to the cinema then do it in style. My mother would never have taken me here. The film itself was easily the best Bond I’ve seen in many years, it was pretty much non-stop action all the way through. Really enjoyed it.

So, probably one more day on the mobile game and that will be it.