This my basic, no-frills blog. It contains both posts about math and other topics. Lately, they've mostly been about linux and vim. I eventually intend to add in a tag and category based word-cloud so that the blog is easier to navigate.

Tag Cloud


2023 Watkins Glen (Part 3)

Read Part 1 and Part 2 first.

“The Auction”

I don’t really know how or why I started looking into auctions, but I had read about websites like Copart and IAAI before on reddit and other fora. These are websites where cars totaled by insurance are auctioned online. These cars are in various states of disrepair: completely smashed up balls of metal to slightly “hail damaged” cars.

The other issue was that since I am in NY, I couldn’t directly bid on these websites. I had to find a broker. There were several options I tried and considered on Copart, since they allowed you to bid directly with a credit card and small deposit. They all had various broker fees (5-7%) in addition to the auction fees. So for example, if I paid 15k for my auction vehicle, the broker fees alone would be 1k; the auction fees are also around 1-2k. Quite substantial! Eventually, I settled on go2auctionsnow.com. It was on a janky web 1.0 website, but they charged a flat fee (150), customer service was curt but quick, and everything seemed to work. The ones with polite customer service hire people specifically to do customer service. If someone is curt and in a hurry, they probably have other work to do. Classic signs of a volume operation. I compared Copart and IAAI, and it turned out that Copart charges 250 for membership and IAAI charged 100. I also liked that IAAI had “engine running” videos, but copart didn’t; they only had pictures. So IAAI it was!

I started out by looking for hail damaged or lightly damaged vehicles that I could fix-up easily. I didn’t have the know-how to do body work, but glass is easily replaced and mechanical parts are easy as long as it’s not the engine or transmission. Frame straightening seemed complicated as well, and not really worth the risk.

There were crazy fights over what I thought were the weirdest cars: an ‘05 4Runner had bids from Tripoli and Benghazi and would easily run up to about 10k-15k. Tacomas sold like hotcakes. Meanwhile, decent looking Fords, Buicks and Chevys sold for a few 100s to a few thousand. The Toyota TaxTM is real.

My original budget was about 4-5k for a Honda Fit or old SUV like the Acura MDX. We really thought hard about this: a cheap Fit is a reliable family hauler that can double as an occasional track car. A Fit would cost maybe 3000 total, including fees and shipping. An SUV in good shape looked closer to 10k. But my wife used her womanly ways on me: “Why not get an SUV that can do it all; tow, road trips, soccer mom stuff”. We have had our old Civic for about 11 years, and it showed its age. Lots of dings and scratches, rust everywhere, and the usual 100k maintenance items: belts, alternator, tensioner, a/c compressor.

We made a large list of cars we were interested in, and started following the auctions for a couple of days. I lusted after a green, single-owner Tacoma for a few days, but then it looked rusty and I learned about the frame rot issues Toyota was having in that generation. There are shops, especially on the East coast, that do frame repairs, but they cost about $1500 that I would have to factor in. I looked into Acura MDXs, but these had oil consumption and transmission issues. Then I saw a GX 460 on IAAI. I hadn’t really considered it before since it was from a “luxury” brand that really wasn’t on my radar. I’m pretty utilitarian when it comes to life, luxury does not do anything for me. But it looked in great shape: it had a reliable Toyota V8, a 6200 lb tow capacity, and the hail damage it was totaled for was barely noticeable.

The previous night, my wife and I had decided we would bid on a few different cars: a few MDXs I was expecting to get for about 5k shipping included, the GX, some 4Runners that I expected would easily get to 20k and hadn’t a snowflake’s hope in hell of getting, and a Ridgeline with a broken windshield. I had put in a $1000 deposit on go2auctionsnow.com so I could bid up to $20000, and had looked at the Carfaxes of all the cars I was looking at; I get them for cheap on some reseller’s website. The GX looked especially good: single owner, one minor fender bender in its early years, and metronomically dealer serviced every 5000 miles. The ACV, or actual cash value was listed at 17.8k, before repairs.

There was a title issue with the GX, but it looked like it was some clerical error after it was totaled! Somebody had misprinted the mileage. I asked a title litigation lawyer (or so they claimed) on reddit and they said dealers do not touch vehicles with title issues, and for private parties with good records, it may not be an issue at all. I smelled a deal: if dealers weren’t gonna bid up the GX, maybe we can get it for less than the ACV! So that night, my wife and I set ourselves a hard budget: 15k. Though we wanted to spend around 5k for an MDX or equivalent, given how nice the GX looked, we were willing to stretch it and take a bit of a risk.

Then came auction day. I was running around at work, and my wife was going to do the bidding from home, but I managed to jump on the computer during a break and took over the bidding, while my wife watched the auction remotely. I tried bidding on a 4Runner, but that immediately went to 28k within seconds of coming up on the block. Goshdarned overlanding crowd. Soon it came down to the GX. It immediately jumped up to 12k from a pre-bid, and it was very slowly bid-up: 12, 12.5, 13… In the end, there were only two people bidding, one from Portland and one from Iowa. As we had predicted, the Texas and California dealers left this one alone because of title issues. Both my wife and I were watching. They traded bids, and it seemed stuck on 17.3 until a last-minute bid of 17.5 showed up from Iowa. My wife sent me a message: “Was that you! WTF! I thought we agreed on 15k.” It was me. My broker was from Iowa. What had I done?

I started freaking out: what if this thing had something horribly wrong with it, what if the engine had rod knock, what if the transmission was on its way out. I couldn’t sleep that night. I kept asking my wife, “What have I done, what are we going to do?” She kept reassuring me: “It’s ok hun, we did the due diligence, we did the work, it will be alright.” “Are you not feeling nervous about this?” “No, I’m feeling oddly calm about it,” she replied. It was very helpful.

The inspection

The next morning, I was in worst-case-scenario mode. I asked my wife to call the IAAI lot and figure out how much it would cost to relist it. “If it’s a dud, let’s get rid of it ASAP.” Surprisingly, seller fees are low on IAAI, just a hundred or so. The buyer ends up paying most of the fees. In the meantime, I also looked into various inspection services that could go to the lot and check it out. Most of the local guys wanted to charge about $300. In the end, I decided to use IAAI’s contracted third party service, carinspector.us. This way, they would have easy access to the car, and I wouldn’t have to worry about coordinating access through the IAAI lot manager. This cost me about $150, but it would take at least 2 business days. I only had about 5 business days to pick up the car! We were on the clock.

I was in Utah or Montreal or some place like that while the inspection was happening. While I was waiting at the airport for my flight back home, I got an email from the inspector. Hands trembling, I opened the email. Engine, check. Transmission, check. No leaks, some not-so-serious electrical codes, probably due to the low battery from sitting in an insurance lot. Phew.

The transport

We weren’t done yet. The next stressful part was getting the car here. Here we enter into the murky waters of the auto shipping industry, with tons of brokers and websites that will sell your contact information and flood your phone and email with solicitations. We’d used a company called TCI Logistics in the past. They found us a driver quickly, and he transported our car across the country safely. We started there again, but their price was quite high. Searching the internet, we were again presented with a myriad of options that made us a little wary. So we spent some time figuring out how this works:

  • There is a national, computerized, unified list of people needing auto transport with car type, pickup and destination, and offer amount listed. This is called “Dispatch”.
  • Brokers have access to this board, and list a price/offer along with pickup and destination.
  • If the transport drivers think the price is right, they accept the offer, and the broker puts the driver in touch with the client.
  • You usually pay the broker a fee of about $100-150 and then pay the driver the rest of the money on delivery.
  • Once you’re put in touch with a driver, you have to ensure the driver carries an insurance policy.

Choosing a broker is the hard part. Some brokers will reel you in with crazy low prices. But no driver wants to take the low offers! So you may have to wait days or maybe weeks to find someone who wants to take your car. So the trick is to do some research online, pick from a variety of places, and read reviews. We were on a time crunch (it had to be picked up rapidly from IAAI, otherwise we would pay a storage fee of about $25-50 a day), and so we had to find a broker willing to ship for a decent price.

Some websites are pretty shady: you put in your shipment details, and they will sell your “lead” to a huge variety of brokers. These brokers will harass you months after you’ve had your car shipped. Avoid such websites at all costs!

Another option is uship.com. Here, you can list your shipment (it doesn’t even have to be a car), and the brokers then bid on your shipment. Uship takes a cut once you accept a bid. It’s auctions all the way down! What I’ve found is that after uship.com takes its cut, it’s more expensive than if you’d approached the same broker directly. But it’s a good way to figure out what a decent price for the shipment is.

In the end, we went with Tempus Logix. They took their cut of about 100-150 for a total of about 800-900. The shipment got picked up fairly quickly by a shipping company that regularly transports between Texas and here. This part went fairly seamlessly, and finally it was here.

It’s here

pic with gremlin A little dirty, but started and ran great. Bonus pic: little gremlin.

Total cost

Item Cost
Auction bid 17500
IAAI fees 1300
Bullshit IAAI fees 350
go2auctionsnow fees 200
Avoidable paypal and wire transfer fees 100
Shipping 800
Total 20250

It was a pretty decent deal in the end. Equivalent cars were going for 22-28k here. It would have been much cheaper if the car weren’t as desirable.

The only things I needed to fix were a radiator leak (they’re known to go at around 100k), and a squeaky bearing in one of the engine accessories. I also did a decent amount of preventive maintenance: oil change, transmission fluid drain-and-fill, etc.

I was so worried about it driving well, but it was a peach. Smooth, clean, reliable. The view from sitting up high in a big SUV was great, and the instant torque from the purring V8 was very satisfying. My wife had her misgivings: “It’s so big, it boats around the corners, it’ll be hard to find parking” etcetera, etcetera, so on and so forth. A week later, I get a text:

text from wifey

I had done good.

The caged track/race car

To be continued…

2023 Watkins Glen (Part 2)

Part 1.

“The Aftermath”

The next couple of months were quite an ordeal. I didn’t have transportation to work, and had to do something quick. I got back on the bike. It was hard work; more than 40 minutes each way! At least I was getting some exercise, and the new bike lanes made me feel a wee bit safer. I did have a rando trucker roll by me when I was in the bike lane and yell at me: “Get the F of the road, you F!” But this is par-for-the-course around these parts.

I spent the next few weeks beating myself up over it. “How could I be so stupid? Why did I deliberately hit the inside kerb to see if I could carry more speed? Why wasn’t I easier on the throttle? Why couldn’t I catch the slide?”

My car had data and video capture. I watched the crash again and again and again. I showed the video to everybody: my colleagues, my students, my wife, and my children, ad nauseum. I lived(!) and relived the moment. Was this some form of therapy?

I took the baby and my older son on several little biking trips. But my wife and I had to split up, so the kids could go to different classes at the same time, and this was becoming unsustainable with just one 15 year old rusty car. So I was in the market for a new car!

“The Market”

I looked at all manner of sports car on Craigslist and Facebook marketplace. The market was recovering from COVID inflation, but things were still pretty bad. I seriously considered an Accord with a blown transmission for 4k!

  1. BMW E46 328, 330 and M3. There were a lot of options in the $15-20k options for the M3s and E46 330s. There were some decent 4 door E36 228s for around $5k, but ultimately, I decided I couldn’t afford to have one of these constantly sitting on jackstands in my “shop”. Old BMWs, though wonderful driver’s cars, need constant care.
  2. BMW 645Ci. These have nice torquey V8s, and generally drive really well. One popped up on my local craigslist that I spent a lot of time and effort looking at. They’re known for leaky valve stem seals and major coolant leaks (remember what I said about BMWs?). The coolant leak had some decent aftermarket fixes, but the valve stem seals needed special tools and the engine out. The one I saw ran ok, and the V8 was nice and smooth. I paid nearly $200 for a nearby shop to put it on their lift (Eurocharged Performance). I wasn’t super impressed with them - you know the vibe when someone judges you on your identity? But they were the only ones willing to take me on short notice. Despite the issues, it was money well spent since we found that it was leaking coolant, differential fluid, engine oil, the tires were shot, the shocks were shot, and it had been repainted. BMW 645Ci
  3. Miatas. We all know Miata Is Always The Answer (M.I.A.T.A), but this doesn’t solve my kid transport issue.
  4. Integras. My first love was a DC2 GSR. See above.
  5. Honda Accord v6 with manuals. Reliable and fun daily that could be good with the kids.
  6. Acura CL Type S. A beautiful handling coupe, but heavy and hardly trackable.
  7. Honda Fit. These have a Time Attack series in Gridlife, and as I later found out, a full-on wheel-to-wheel racing series in the SCCA called B-SPEC. They were cheap (sub 5k), manual, easy to work on, reliable.
  8. Civics. These are great cars, especially the 5th through 8th gens.

My options are all over the place, aren’t they? What did I want to do with the car? Did I want it to run in a SCCA race series? Did I just want to get back to doing HPDE? Did I want to run away for six or seven weekends every the summer, leaving my wife to manage my kids?

The other option was to buy a truck or something that can tow first, and do it properly:

  1. Buy a caged, dedicated race car. It would be safe, and I wouldn’t be risking my daily driver.
  2. Buy a go-kart. Then I could take the kids with me. It was much cheaper, easier to go wheel-to-wheel racing, and you could get lots of track time.

Trucks and SUVs

The idea was to get a reliable family hauler that could eventually tow a track car or go-kart. We quickly narrowed it down to a few candidates, based on vehicles that could tow at least 5000 lbs (2500 Miata + 2500 trailer).

  1. Honda Ridgeline: 5000 lb tow capacity, nice unibody frame so it would be smooth on long journeys. A truck bed that could haul lumber and maybe a go-kart.
  2. Toyota Highlander. Famed reliability, but the tow capacity depends on whether it came with a tow package or not. This was hard to determine from pictures alone, and it depended on the build sheet and dealer- and owner- selected options. I now know that you can look at the build sheet on toyota.com.
  3. Honda Pilot. The Pilot has decent tow capacity in the top trims with the tow package, but if it doesn’t have the transmission cooler, the tow capacity is only 3500. Like the Highlander, it was hard to determine whether or not it came with the tow package. That said, both the Pilot and the Ridgeline are built on the same platform, and the Ridgeline has a 5000 lb tow capacity stock, so the Pilot can easily be modded to up its capacity.
  4. Acura MDX. As far as I could tell, this was more or less a more upscale Pilot. This has a better engine that the Pilot; or at least, it has many minor mods that give it extra horses. All trims come with a 5000 lbs tow capacity. However, early models had some issues: transmission blow ups and oil consumption (see this 2012 on mdxers.org and this 2010 on mdxers.org). However, overall, it is a very reliable vehicle. You just have to be careful about which generation you buy so that it doesn’t have the transmission or oil-consumption issues. The J35A5 and J35A6 Honda V6 are an interference engine (the valves overlap with the pistons), and have timing belts. If these aren’t serviced, then the timing belts could snap, leading to the catastrophic engine failure. So you should get one that has been correctly serviced at the right intervals. Incidentally, the BP engine in the early Miatas is non-interference. So even if the timing belt snaps, it wouldn’t explode. See how I told you Miata Is Always The Answer?
  5. Toyota Tacoma V6. It’s the taco truck, what else can you say. Famed reliability, but ridiculously expensive. The very definition of the Toyota TaxTM. Many, many, generations were plagued with frame rust issues and recalls. So one would have to be very careful with older vehicles from the rust belt. The 4-bangers had a pretty low tow capacity (3500), so those were a no go. The V6s were snapped up within hours of being posted on craigslist or marketplace. The ride quality was supposed to be bad, so maybe it wasn’t such a great vehicle for family hauling.
  6. Toyota 4Runner. Again ridiculous prices thanks to the Toyota TaxTM. But it also has the usual, famed Toyota reliability, especially its famed 1GR-FE V6 engine. These are coveted by the offroading crowd. They come with tow packages by default, with a minimum 5000 lb capacity. Not a great ride, since it is a body-on-frame like a truck, so not so great as a family hauler. But many people love these, mod these, lift these and hold onto these for dear life.

There were several other BMWs, Volkswagens, GMs and Fords on the list, but they all fell short on the reliability criteria. If I had to do it again, I would consider a 99-07 Tahoe with the 5.3L V8. Lots available for cheap. It’s a typical GM: it will run badly forever.

So with these options, I started looking. There were not too many on Craigslist and Marketplace in the 4-5k range, which was, more-or-less my budget. We test drove a couple of cars at a Honda Dealership: 2018 and 2020 Pilots and Ridgelines. The Ridgeline drove exceptionally well. But these were in the 30k price range at the dealership. There was a locally available 2014 Ridgeline with 120k for about 14k, but even that wasn’t super impressive. Moreover, it had had an accident and it was kind of rusty. There were several Tacomas, but nothing close by, and the best examples were usually snapped up within the hour.

Part 3.

2023 Watkins Glen (Part 1)

“The Crash”

In the early 2000s, I owned a blue Acura Integra. It was a load of trouble, but when it drove well, it was great: the handling was tight, it had a beautiful shifter and the 8000 rpm redline was intoxicating. I had to sell it when I moved to the City (someone drove all the way from Manitoba to pick my car up), and then life and career got in the way. But a little sports car had been calling my name in the intervening years. Acura Integra (The work wheels were put on by the next owner)

Much later in life, when I was financially stable, despite having a one-year-old baby, I bought a Toyota 86. I tested Miatas and other cars, but I wanted to do track days and decided I didn’t want to deal with putting a rollbar in a Miata. Moreover, I preferred having a 2+2 (a four-seater coupe) so I could drive the kids around if I had to.

I did my first track day at Watkins Glen in 2021 and was hooked. The Glen is a historic track. It held one of the earliest US Formula 1 Grand Prix in 1961, a couple of years after the first ever US Grand Prix at Sebring in Florida. It continued to hold F1 races until the deaths of François Cevert in 1973 and Helmut Koinigg in 1974, after which there was a slow decline until its final cancellation in 1981. Since then, it has been upgraded and both NASCAR and IMSA run there.

I was looking for cheaper seat time, since the Glen is around $300 a day, and came across a little local track called Pineview Run where you could get track days for around $75-100 a day. I did about 6 track days in 2022 at Pineview Run. In 2023, I continued going to Pineview and did about 5 days there, and I was looking forward to my only visit to the Glen later that year. I did have a minor incident where I lost the rear end, hit a curb and chipped a wheel; but no real damage was done. I knew I was starting to push the limits of myself and the car. So I used the opportunity to put on some new Pirelli PZ4 225/45 rubber. A bit thicker, and bit grippier than my previous all-seasons which would whip the tail out if I breathed on the throttle. It’s a Michelin Pilot Sport 4S equivalent (at least according to Tirerack and tyrereviews.com), the quintessential dual-duty performance tire.

Pineview Run is pretty safe, and it’s hard to mess up very badly there since there is lots of run-off. The only negatives are maybe the tarmac isn’t so great, and you have to stay completely off the curbs since they are so high. It’s pretty popular, and there are always people there. I liked Pineview Run. Some people say that they have had disagreements with the owner, but I really have nothing bad to say about the place. That said, it’s no Watkins Glen, with its high speed curves, hard braking zones, and narrow confining baby-blue steel barriers. The Blue Heaven, if you will.

I was really excited to go to Mass Tuning’s event at the Glen. In my previous HPDE (High-Performance Driver Education) at the Glen with the BMW Club, I had had a very good instructor. She was very methodical and very cautious; a little too cautious, I naively thought. Mass Tuning’s HPDE was very different. It was mostly just one guy managing the whole show. Everything was very chill, you could get an instructor (or not), and choose your own run group, more or less. I had a good instructor, I forget his name, Ryan xxxxovic or something. He was super encouraging, and seemed impressed with my driving progress, and said “You’re driving at an intermediate level. You cleaned up your lines when you went out solo! That’s awesome.” Yo! Don’t say nice things to me, it’ll go to my head.

The day went well, and I managed to hunt down an Alpha 4C in the evening. I had previously spoken to the owner of the Alpha, and he wanted to go out together on track, and have some fun. I thought there was no way I could keep up with or catch him in his high-strung Italian sports car. But I did, and it was nice. He was very cautious, avoiding the curbs, and I was flying like a maniac, clambering all over the curbs to save milliseconds. It was very thrilling.

Track days and HPDE are more about community than anything else. It’s mostly a bunch of car nerds, obsessed with little mechanical details and milliseconds of laptime. My kind of people. I spoke to a couple of BRZ guys to figure out what mods they had on. There was a wide range of ability and car-prep. There was a guy in a supercharged, or at least, fully tuned BRZ with headers, suspension and 200TW tires. He was running in the 1:21s, which was very quick for our powerless little cars on a power track. For comparison, I was maybe running in the mid 1:30s. There was another beginner in a blue BRZ that was on his first track day and was very slow and unpredictable. I offered some advice about data capturing and stuff like that since I was more “experienced”. I saw a nice white BRZ tS driven by a kid from Boston who had had an incident and triggered his right airbags. I didn’t know what to say to him, but I suggested he have it towed to Boston instead of trying to drive it back. I felt really sorry for him at that time, given that he seemed so young.

Later that evening, I went and got dinner at a Thai place, and hung out with an airline pilot from Mass or Rhode Island or thereabouts. He was a cool guy. He tracked his Elantra N, and we both talked about parenting, our risk tolerance and how we both feel safer because we have track insurance. We discussed the oiling issue in the FRS/BRZ, and how I was running Redline 0W20 since I was worried about high oil temperatures and oil starvation in FA20 engines. Oil starvation would turn out to be the least of my worries.

That night, I camped out again under the stars in the little grove past the paddock. I started cold weather camping about 10 or 15 years ago, and I much prefer it to summer camping. It’s cold, quiet, and there no bugs. It went down to the 30s, rained a bit, and the ground was a bit uneven. So it was hard to get comfortable, but my sleeping bag was good and I was probably a bit too warm.

I wasn’t driving on Day 2, but I went out with my instructor in the morning in his car. He had a nice, fully-prepped, stripped and caged Miata. On the first lap, the flags were out, and there was a white BRZ in the wall at turn 10. After he hit the curb, his right rear must have had too much grip and his left too little, thus spinning him out into the left wall. The word on the paddock was that this guy was known to be super aggressive in previous events, and that he was crazy to have pushed so much on the first lap. I also saw a Formula Vee in the wall with a completely broken right rear suspension. Formula Vee is one of the biggest amateur racing open-wheel classes in the SCCA. I would never be so stupid now, would I, I thought. I would take my time, get the tires warmed up, feel out the track for grip, and then maybe start to push.

My kids had really wanted to watch me “race” my car, and were coming to join me later that day. I had booked a room at the Seneca Lodge so they wouldn’t have to camp out in the cold. Seneca Lodge is an amazing place with a lot of racing history and memorabilia; highly recommended. I went to a diner to get a good lunch. I had been eating packed sandwiches for most of my meals and wanted my second hot meal of the weekend. Curly’s restaurant hit the spot. Then I went out and got a coffee in Montour Falls at a place called North New York. The espresso was decent, and they buy coffee from a local roaster who was (formerly?) a physicist at Cornell. They suggested Jerlandos or the library as a place to hangout until my wife and the kids showed up. So I did both: I got a slice at Jerlandos, and went out to the library, which was a cool little space with a playroom the kids would have enjoyed. The family finally arrived at the Glen. They had had a long drive, and the kids were a bit cranky, so a bit of R&R was in order.

After resting up a bit, we headed out to try and get a parade lap at the Glen in the old rustbucket. However, we were stuck waiting in line for more than an hour because there had been another incident in the evening. This was getting a bit much, right? I had never heard of an event with so many crashes. After waiting for a while, we abandoned the parade lap and went out to get some pizza in the nearby town. Our room was super comfortable either: it right under the bar, it was loud at night, and there was a pillar running through it that I kept bumping into. Remind me not to book that room again. #traveltips. All in all, not a great night, and I would have preferred sleeping under the stars.

I was driving again on Day 3. I got up early, and went straight to the track, while my wife wrangled the kids through their morning routine. I was nervous about driving in the intermediate group since my car was slow and there had been so many crashes, but I psyched myself up and decided to go for it. I took it real slow in the first few laps, and slowly gained confidence. I stayed off all the curbs and paint. I braked well before the braking zones. But I was getting faster and faster, and conditions seemed OK - at no point did I feel like I was going to lose control. I passed many people, and was given a few point bys. I was still driving well within my limits. On maybe my 6th or 7th lap out, I took the curb coming out of Turn 8, and it felt real good. I took a wee bit of exit curb on turn 1 as well. On the next lap, I decided I wanted to feel a wee bit of inside curb on turn 1, and carried a little bit more speed through the corner. This put me wider out on the exit of turn 1, with my left wheel on the outer part of the exit curb. That part of the curb had a bunch of deep grooves that held water, and given the temperature was 30F overnight, it was probably ice. As I got on the gas, I lost the rear immediately, and started to spin. I was just a passenger as the car careened towards the wall. It all happened in a fraction of a second.

I didn’t black out or lose consciousness. I was well aware of what happened, and during the spin, even felt that I got on the gas too aggressively. I was thinking: “Oh F! It happened to me. I never thought it would happen to me.” After hitting the barrier, my car came to a stop. My head was stuck under the airbag. I got out from under it, and checked myself. I remember thinking, I only hit the clutch and brake like you were supposed to after I hit the wall, so I did roll back onto the track after my impact. That could have been dangerous.

The firetrucks and the medics pulled up. The medics checked me out, asked me where I was in the parking lot - in fact, he asked me where I came from and I said “Rochester, NY”. Then the guy said, sorry, my fault, let me clarify: “where were you parked on the parking lot?” The ambulance guy asked me to sign off on a waiver saying they asked me if I wanted to go to the hospital. He said, “You look fine, take some ibuprofen for the soreness.”

Back at the paddock, the adrenaline was still coursing through me. I called my wife: “I had a track incident, but I’m ok.” I ought to have inverted those clauses. Spoke to the organizers: “What did I do wrong? How do I make an insurance claim with track insurance? Has anyone else crashed before? How did you deal with it?” Hugged the friends I had made. Looked around for a body shop and tow truck. Eventually decided to just leave it at the “Boneyard” at the Glen, a bunch of mangled up cars that people have left behind after their crashes. Some car-guy gallows humor for you.

Aftermath

It was a long drive home. My wife was very supportive, just happy I was alive. I was happy that I had gotten track insurance earlier that year.

Part 2.

Bash cd function

I have a cd function I wrote for bash that I kind of like. It has two pieces of functionality that are probably quite useful:

  1. If you cd to file via

    cd <filename>
    

    it takes you to the parent directory.

  2. The cd command stores the last directory you were working in in a file $HOME/lastdir. In combination with

    urxvt -cd `cat $HOME/lastdir`,
    

    I can quickly fire up a new terminal to the last directory I was working in. I think there are other ways to do it, but I like my way since I am able to add exceptions to the lastdir functionality. For example, if I am in a remote filesystem or nfs directory, then due to various problems (e.g., poor network) the urxvt -cd command will hang and take forever.

    function cd
    {

        ### Configuration ###
        # assigning "$@" to a variable helps somehow.
        args="$@"
        host=$(hostname -a)

        # logfile for cd command. Set to empty to not log.
        logcd="$HOME/logs/cd-${host}"

        # if the current directory matches a list of exceptions, then do not write it to .last_dir
        except_dirs='/mnt/sshfs /mnt/box-remote /mnt/nfsmount /media /run/media /home/arjun/201-sshfs'
        ### End Configuration ###

        # the builtin cd is to avoid recursion
        if [[ -f "$args" ]]; then
            # if asked to cd to a file, find dirname and cd to it
            if ! builtin cd "$(dirname "$args")"; then
                return 1
            fi
        else
            # directly try the builtin cd on
            if ! builtin cd "$args"; then
                return 1
            fi
        fi

        cdir=$(pwd) #current directory that the builtin would have changed to if successful
        if [[ -w "$logcd" ]]; then
            # if logfile for cd is writeable
            echo "$cdir" >> "$logcd"
        fi

        for x in $except_dirs; do
            if echo "$cdir" | grep "$x" > /dev/null; then
                return 1
                # cat $HOME/.last_dir
            fi
        done

        # if any of the except dirs had matched, it would have exited
        echo "$cdir" > $HOME/.last_dir
        return 0
    }

The amdgpu driver on linux

I use a Radeon 7950 (Tahiti/Southern Islands) GPU on linux to run a 4k LG 32UD59 32” monitor. The old radeon driver doesn’t work so well; the colors are reddish, and the picture is not sharp.

TL;DR The amdgpu driver is great with colors and supports displayport and HDMI. But it does cause a lot of problems with hibernate, and crashes firefox when hardware acceleration is enabled. I have listed my hacks for this problem.

So I made forced my kernel to run the amdgpu driver by setting

blacklist radeon

in modprobe.conf. Then, you include the following kernel options

 radeon.si_support=0 amdgpu.si_support=1 

Which tells the kernel to enable the amdgpu driver for southern islands cards.

The new driver is not bad, but somehow, it really needed the amdgpu-pro driver from AMDs website to get a sharp image. On my debian stable installation, the amdgpu-pro driver installation script has to be tweaked to disable checks for ubuntu, and once you do that, it installs without any errors. The pro driver is a proprietary driver that works on top of the open source amdgpu driver. I have two main problems with it:

  1. Hibernate
  2. Firefox crashes

Hibernate fails every once in a while on the new driver, since it complains about a lack of swap space to write the hibernate file in. This is because the amdgpu driver appears to be allocating a bunch of unnecessary space for some strange reason. So I have to get the systemd-hibernate.service unit to restart. This is a pain in and of itself, since the systemd-hibernate.service is of type oneshot and hence cannot be restarted easily. Hence, I used this fail-notify@.service from the systemd github page:

/etc/systemd/system/fail-notify@.service

[Unit]
Description=Restart a failed service, implements Restart on-failure for simple/oneshot
# Enable by specifying OnFailure=fail-notify@%n.service AND #RestartSec=xxx

[Service]
Type=oneshot
ExecStartPre=/bin/sh -c 'systemctl set-environment SEC="`systemctl cat %i|grep -Po \\"^#RestartSec=\\K(\\d)*(?=s?$$)\\"`"'
   ExecStart=/bin/sleep ${SEC}
   ExecStart=-/bin/systemctl restart %i

Then in /etc/systemd/system/systemd-hibernate.service I had

[Unit]
Description=Hibernate
Documentation=man:systemd-suspend.service(8)
DefaultDependencies=no
Requires=sleep.target
After=sleep.target
OnFailure=fail-notify@%n
#RestartSec=30

[Service]
Type=oneshot
ExecStart=/lib/systemd/systemd-sleep hibernate

On firefox, I simply disabled mutliprocess tabs by going to about:config and then toggling the

browser.tabs.remote.autostart = false

It seems much more stable after this. Perhaps it is the hardware acceleration that is failing as well, since I do get gpu crashes induced by firefox pages in the systemd journal. There is another option to remove hardware acceleration in firefox, but I enjoy my 4k videos, and although I am not sure, I feel like they might be gpu accelerated.

Note that some people have noted stability improvements by removing 2d acceleration by using an Xorg setting

Section "Device"
    Device "amdgpu"
    Option "AccelMethod" "none"
EndSection

but this seems to defeat the purpose of a graphics card.