Tuesday 4 August 2009

Unix syntax in windows

Ok so not the greatest first blog but still something worth sharing I thought.
Unix syntax in Windows. I know not the most exciting topic but this completely caught me off guard recently and I spent hours trying to figure out the problem.
So here it is MAC user phones IT support desk folders created from one MAC are inaccessible on another. However Folders are created in a windows share, which is also accessed by 15 PC users or so. PC Users also can not access files.
Initial thought ntfs permissions problem, so pop on to server take a look select folder, right click properties....... No security tab.
Odd right so try the usual taking ownership ect no joy.
Then I notice there is a space after the folder name something a mac will let you do even on a windows share. But syntax that windows doesn't recognise, bit like those system files on a mac that have '.' at the end 'entouragesys.' end up in your windows profile and you can't delete them.
So I googled ignoring folder syntax and eventually found '\\?\' so if you put that in front of the folder name with the rmdir command it works, directory deleted.
rmdir "D:\sytem folder\irrelevant\genius " (notice the space at the end of the folder path) But wait theres more........

I wasn't satisfied with that so tried using '\\?\' with the rename and ren commands no joy. Then decide to browse through the help commands again.
Used the dir command, gave me a list of directories nothing unusual. But I noticed something the dos 8 character name it still exists. When you browse the directories the postcards and certificates directories still come up (16 character names) the syntax isn't recognise so they are not 'registered' if you like.
However force PC DOS to use 8 bit names and suddenly they become postca~1 and certif~1 . The magic command to do this dir /x. However you have to be in the directory to do this.
D:\sytem folder\irrelevant\genius>dir /x
Ok so we can see a list of 8 character folder names now what we still can't access them?
Well I'm glad you asked lets rename them, How? you say. Well read on.....
D:\sytem folder\irrelevant\genius>ren postca~1 postca~2
We rename them using the 8 charcater format.
Once renamed the folder then appears in the explorer window as an 8 character name 'postca~2' so best to rename again to something ledgable from explorer or from PC DOS if you like.
D:\sytem folder\irrelevant\genius>ren postca~1 postca~2
D:\sytem folder\irrelevant\genius>ren postca~2 Postcards
Possible problems only if the folder name is shorter then 8 characters. But then we can still copy content out and remove the directories using '\\?\'.
Could also use /a switch with the dir command to show hidden folders. ">dir /x /a" hope this helps.

Sunday 2 August 2009

Welcome to the tech know.....

Ok so the name of the blog I could have put a bit more effort in.....
But let me introduce myself I'm Aaron or Aza and I have so many industry colleagues that have a blogspot, I didn't want to be left behind and decided to get one for myself. I'll be blogging on what I'm doing as I do it. Over the last 18 months, I have gone from a network novice or newbie to someone with more advanced knowledge. My IT career started in high school building and repairing PC's still a hardware freak now. But have a few more creds to my name A+, N+, MCSA, MCTS, and am currently working on my MCSE, CCNA and JNCIA-EX. I have spent a few years dealing with desktops and servers and various windows related stuff. However I steped up to fill some shoes (big shoes I might add) about 18 months, Our network guy was leaving for bigger and better things...... you can check the dude out here http://cytraxtech.blogspot.com
Due to staff absence at management level, someone had to feel in until a job advert and interviews could be arrange. My name came out the hat and I stepped up to plate. Anyway three months later advert was put out and I applied under pressure from higher up the chain. Got to be honest didn't think I was up to the task. Got the post permanently and haven't looked back.
So I'm going to put a few posts up over the next couple of weeks on the stuff I have covered over 18 months, here is a taste.
WAN fixed, leased, VPN - you get my vibe
SSL VPN and Microsoft IAG - soon an update on UAG
Juniper Swithches and Junos - Why I think this is great also why we picked it over everything else.
Trapeze wireless implentation and Ringmaster - Not quite finished yet but looking forward to this.
Managed or unmanaged VOIP solutions - Be careful what I put in here could cause a lawsuit
IPV6 alongside IPV4 - you should get this about november I'm working on this one.
Microsoft active directory structure and Group Policy - I'm not going to blog on this til I have spent some time looking at the 2008 version a friend at microsoft tells me this has had some improvement.
Exchange 2010 - I'm running the beta of this but I also want to talk about public folders and whether sql is not a better option then edb? and why microsoft haven't made this move yet.

So lots to look forward to I'll try and get my first blog up by Friday the 7th.