A Major Fire in the Neighbourhood

Posted on December 28th, 2009 in Vancouver by andrija

I looked through the window to see what’s up with so many sirens. And indeed something is up. The smoke was black and there was lots of it. I am not sure where exactly it was, looks like Kingsway and Rupert, somewhere behind the hotel.

OLYMPUS DIGITAL CAMERA

UPDATE: apparently this was a two-alarm fire (really?! but look at all that smoke!) at Big O Tires, an automotive repair centre. That makes sense, the black smoke could be from tires. And now, an hour later, not a whiff of smoke is coming so I guess it wasn’t as bad as it can get.

USB External Drive Freezing and Stuttering on AMD 785G in Windows 7

Posted on December 24th, 2009 in Hardware & Software by andrija

The other big problem I was having with my new PC is actually much worse than the first one (eSATA hotplug issue). Unlike that one, here I have no idea what was causing the problem. Basically, every time you plug in an external USB drive, no matter which one, the results are unpredictable. It may work for a while but try to copy a file to or from it and after some time it would freeze. Not just slow down or temporarily stop while cache is being drained, but freeze for several minutes. The PC itself would still run although if you tried to force the copy to stop it might just stop working as well.

Now this was really serious: since I wasn’t able to use eSATA effectively I needed to rely on USB for backups – and I wasn’t able to! So I tried to work around this and bought an enclosure with both USB and Firewire. Guess what, the Firewire was even slower! I can’t recall if it was showing the same symptom – I think so but I am not sure – yet the result was just as bad.

This is where firmware flash comes in, as I was sure there was some sort of interrupt sharing problem and those are usually solved by firmware flash. But for the longest time I wasn’t aware there was a new firmware. At any rate, eventually my Corsair Xtreme 64G drive died and things got put into motion…

But the problem remained after clean install, firmware flash and setting of drives to AHCI. So in the moment of desperation I decided to replace the cable. At that point, I also realized USB cable was plugged into a hub. I am pretty sure I tested this both with and without hub and it never worked well. Yet now after replacing cable and plugging the drive straight into a motherboard USB port, drive was finally working correctly! It took me months to sort this out! And I am not sure is it a combination of issues or a single issue – I believe it must be a combination since I’d imagine I used a few different cables plugged into various ports during all these months. I just took a five to go back to my desk and plug in the “old” cable and – guess what, it’s still working. It does appear to be a bit slower – say 25MB/s compared to 27MB/s – but this may well be a statistics fluke. So, the hub connection then? No matter, I guess for now it appears to work so I’ll keep it plugged in and don’t mess with it.

Unresponsive SATA Hot Plugin with Windows 7 on AMD 785G PC

Posted on December 24th, 2009 in Hardware & Software by andrija

I have had serious issues with hard drives on my main PC for months now. First was the issue when using hard drive dock. The way it worked on my old PC was like this: with the dock turned off and eSATA cable plugged into it and the PC, you plug the hard drive into it and then turn on the power to the dock. PC should automatically recognize it – and it would, on my “old” Intel P35 motherboard. Not on my “new” AMD 785G motherboard with Phenom II 955. Well, I wasn’t expecting it anyway seeing as I was running my SATA ports in “Native IDE” mode.  The idea here was that since I was using an SSD drive (plus a regular HDD) I needed to run it as “native” in order to get TRIM instruction to work. TRIM support is what you need in order to prevent SSD performance deteriorating over time; if you don’t know why and how, hit Anandtech’s legendary article on the subject.

Anyway I wasn’t really able to use external dock to a great extent or, frankly, at all. A drive would only get recognized if it was plugged in and turned on before the PC itself was turned on. There was a trick one could use, where if the PC was sleeping you would be able to do the deed. Since sleep/wake cycle is much faster than a full shutdown/restart, this wasn’t too awful. But you couldn’t remove the drive while PC was running either – unpredictable results would occur. And often I’d either forget to put it to sleep or would have a reason to not want to put the PC to sleep (ongoing download, music conversion or whatever). So this was a big pain.

Due to my SSD dying recently, I had to reinstall Windows so I took the opportunity to set BIOS to AHCI. Unfortunately it didn’t go as smooth as it should have. I first tried to restore drive from a 10-days old full image and while that worked (more or less), the system would only boot if the drive was set to native IDE; set it to AHCI and poof, blue screen during boot. I thought this was because I replaced SSD with a HDD but no. I got Intel’s SSD and restored image to it, and the result was the same.

I decided to update BIOS. For some reason I thought there was no BIOS updates for my Gigabyte motherboard but lo and behold, they were all the way up to F5 while mine was still the original F1. I had big hopes because I had big problems (in addition to this hotplug, I had major dropout issues with USB, Firewire and keyboard not being recognized at boot time, all addressed in upcoming posts). AHCI looked much nicer – and faster – in BIOS this time ‘round but it was still giving me the blue screen.

So I did a full reinstall from scratch, using AHCI and F5 BIOS. Yay, it worked. Of course, I had a blank slate of a system. But to add insult to injury my eSATA was still not working!

Now I was getting nervous. I knew I probably needed to install chipset drivers but I was avoiding it because unlike AHCI I was definitely sure that only the virgin Microsoft SATA drivers supported TRIM. If I install AMD drivers, no more TRIM. Right?

Well it turns out my brand new Intel SSD did not come with firmware supporting TRIM anyway! What the?! The thing was delayed for months because of that and now that it’s finally back in stock, it’s still using old firmware? I had to deal with this as well, now. Funny enough, flashing Intel SSD firmware involves booting off a CD into a custom DOS-like OS. And it didn’t recognize my SSD until I reverted BIOS to “Native IDE”. Anyway, I flashed it, turned AHCI on again and it booted up fine. At least some good luck, I’d have hated it to end up with a wiped drive or much worse, a RMA-ready one.

trim is a go

Once in the Windows 7, I ran the CrystalDiskInfo and it was showing TRIM as supported (before firmware update, it didn’t – that’s how I knew something was up). Now does this mean TRIM is supported by the drive or that it’s supported by the whole chain (OS, drivers, drive)? I do not know, but after finally installing chipset AHCI driver (available from Gigabyte or AMD itself), it was still showing TRIM as supported. I’ll take my chances for now as the worst that can happen is that the drive gets slower over time (and there’s a lower boundary of how slow it can get so it’s not a disaster by any means).

And on the plus side, after installing AHCI chipset drivers, hotplug of eSATA drives is  working like in good old times! Plug in, turn on – it’s recognized in seconds after spin-up. Turn it off, OS recognizes the fact and removes it from the drive list cleanly.

How to Access Windows 7 Shares From Network

Posted on December 12th, 2009 in Hardware & Software by andrija

There are many articles on how to get  non-Windows machines to access Windows 7 shared files but I found it the hard way that there’s always something amiss. So here’s my take on it.

First, if you have the ability to use Homegroups – then use them. While right now this is limited to networking between Windows 7 machines (and perhaps some other Microsoft devices), it’s the way of the future. Homegroups are simple to set up, (probably) secure and most importantly, they just work. No messing with user names, machine names, domains, workgroups, NETBIOS and God knows what other arcane Windows networking lore.

But if you have to access Windows 7 files from a device such as O!Play media player or another linux box, then you might have to work at it.

It would be good if you could restrict access only to authenticated users but I was not able to do so or find any guide that allows it. Therefore only anonymous access will be allowed which is very convenient and very insecure. So bear in mind that there’ll be little to no security on those files that you allow access to. Therefore only share stuff that is intended to be public using this method. I.e. share your multimedia but don’t share your private financial documents and serial numbers and such. Or if you do make sure you’re on the private network.

You can use Homegroups alongside “classic” shares – that’s what I’m doing, with the intention of eventually retiring classic sharing, though I have no fantasies about that happening any time soon.

Go to folder you want to share using Windows Explorer and right-click on it, select properties. Go to Security tab and click “Edit…”. Now click “Add..” and type “Everyone”, click “Check Names” and then “OK”. In short, add “Everyone” to the list of “users” that can access this folder. It may already be there, depending on what are you trying to share.

Now we need to let Windows 7 know that “Everyone” includes anonymous. There actually is “ANONYMOUS LOGON” “user” defined but I was not able to get it to work. So be aware that from now on everything that has “Everyone” in its security list will potentially be available to anyone who can see your PC regardless of whether they have any kind of account on it. To do this go to Local Security Policy – just click on the Windows button and start typing in the search box, you won’t even have to type more than 2 letters before it shows up. Alternately you can go to  Control Panel, open System and Security, Administrative Tools and then Local Security Policy. Anyway, go to Local Policies, Security Options and scroll down to “Network access: Let Everyone permissions apply to anonymous users”. Set this to “Enabled”. Don’t close this window, we’ll change a few more options.

Make sure that Restrict anonymous access to Named Pipes and Shares is disabled. Alternately, you can let it be enabled and then manually enter all shares you intend on being available anonymously using the “Shares that can be accessed anonymously” setting. This might provide better security.

Next, Sharing and Security Model for local accounts should be set to Classic.

There are several other settings that should not be touched if they are at their defaults. Those are:  Accounts: Limit local account use of blank passwords to console login (should be enabled), Network access: Do not allow anonymous enumeration of SAM accounts and shares (disabled).

Make sure Guest account is disabled.

Now go to Control Panel, Network sharing, Change advanced sharing settings. Turn on network discovery, file and printer sharing and public folder sharing (you might not need it but the music and video I want to share are in the public folders). Finally, turn off Password protected sharing.

Now reboot and you should be able to browse your

Windows 7 PC and access folders you designated as shared to “Everyone”. A few things to note: changing settings through Local Security Policy can cause a change of options in the “Advanced Network Sharing” so you should do those changes last. E.g. password protected sharing tends to get turned off often in my experience. You also may need to first stop sharing folders and remove “Everyone”, to start from a clean slate so to speak. If you use Homegroup sharing you might end up “competing” for privileges on some folders so you may not keep removing/adding Homegroup – e.g. right-click, “share with…’”,  “Specific people…” and so on.

UPDATE: As I witnessed again yesterday, it looks like Homegroup networking is really not compatible with “classic” SMB file sharing. I have copied a file from my laptop to my PC via homegroups and suddenly my ASUS O!Play was not able  to access any folders; it was able to log in and see the list of folders but that was it. I had to: disable Guest account AGAIN, reboot, disable password-protected file sharing AGAIN but only after half an hour of fiddling with shares and their security settings. In summary, don’t expect to be able to use both methods of sharing at the same time. Read access may work but as soon as you do any writing to the “server”, it will have some of its settings reset. I hope developers start switching to Homegroups for Windows file sharing ASAP – it’s really a better, simpler method. I am not sure how open Microsoft is to this though as nothing but Windows 7 and Xbox 360 support it right now.