How do I restore Long File Names?

Toshiba / Um
January 8, 2009 at 12:31:13
Specs: Windows 98SE, 64mb
All the file names on my Win98se computer have changed to 8.3 DOS format! I think Scandisk did it. I rebooted in MSDOS mode and then ran Scandisk with the custom switch, this time Scandisk took longer than normal. (Normally I just do Scandisk C: /autofix /nosummary /surface) During this longer than normal time it must have been converting the file names.

I looked in the Scandisk settings ini and the setting for 'Lfncheck' was set to 'off'. I had set it to 'off' because I already knew that I had long file names and didn't want to check for something I already knew existed. However, I have later read that if you set this to off and put autofix on, scandisk will convert your file names to 8.3!

So anyway, how do I get the proper long file names back? I ran the sulfnbk.exe, but it wouldn't work, complaining that I didn't already have a back up of long file names.

I know the information for the long file names is still on the hard drive somewhere because I ran a freeware file recovery prog called Disk Investigator ( ) and Disk Investigator has 2 columns, one called file name, where the Long file name STILL is and one called MSDOS name, where the 8.3 name that Windows Explorer and all other programs now show. So if Disk Investigator can still see the long files names, then this information must still be there somewhere. So the question is, how do I restore all the long file names?

See More: How do I restore Long File Names?

Report •

January 8, 2009 at 15:15:23
Here's something to try, I don't know if it works:
"One easy way to restore long file names that have been truncated is to move them to the Recycle Bin and then restore them. The file names will be restored as well, in most cases."
It's from someone else, I've never personally tried it. Never had the long file names truncated except when I created a CD-ROM without the "jolliet extensions"...

Report •

January 8, 2009 at 16:18:23
Thanks for the response. I looked in my Recyle Bin and the files that were ALREADY in there had not been renamed to 8.3. So Scandisk mustn't have renamed the files in the recycle bin for some reason.

But when I deleted a file that had been converted to 8.3 and restored it, it didn't get converted back to the long file name. So that technique doesn't work for me.

Also, the file I just put in the Recyle Bin and then restored DOESN'T have the longer file name version in the "file name" column in Disk Investigator anymore. The file restored from the Recycle Bin now has an 8.3 name in both the DOS name column and the standard file name column.

I'm wondering where Disk Investigator is getting the longer file name versions from, could it be the second FAT table?

Report •

January 9, 2009 at 00:53:43

The circumstances of its recommended usage are different than your problem but it might work.

It might seem silly but did you try re-running scandisk with LFNCHECK set to 'on'? Maybe it'll reverse the changes.

Report •

Related Solutions

January 9, 2009 at 13:33:47
I understand it's tedious, but if this Disk Investigator can "see" the original long file names, can't you use it for renaming the individual file names? The fact is, most files which are called by programs, such as DLLs, are in the 8.3 format by convention. The long files names are mostly just for allowing more "human readable" file names. As long as you know what the file is, it's not that important that you get back the original long name. It is important to restore all the long directory names, however.

Report •

January 10, 2009 at 10:14:14
Thanks for the link. I downloaded the bootable Floppy demo version of Uneraser and it was able to see the original Long File Names, pressing TAB+SHIFT made it toggle between the original LFN's and 8.3 DOS filenames. So that's 2 programs now that can see the original Long File Names!

I decided to run Scandisk again, this time in Windows rather than DOS with the following settings:
autofix turned off,
check for invalid filenames = yes
report MSDOS mode length errors =yes
check for duplicate names = no

it came up with lots of errors, I ignored them all apart from 1 just to test what would happen if I let it fix the error, here's what it said in the Scandisk log:

folder was damaged:
This folder contained one or more long filenames that were no longer
associated with files.
Resolution: Repair the error
Results: Error was corrected as specified above.

When I checked this folder in Windows Explorer afterwards, the original LFN hasn't been restored so I don't know what error it was correcting. I checked it in Disk Investigator and it can still see the original LFN ( C:\Windows\Start Menu\Programs\FastStone MaxView ), so nothing seems to have changed when it got fixed.

Programs built into Windows like Internet Explorer and Notepad are still working OK, but others, like Opera aren't working and have too many files and subfolders that would have to be manually renamed. I just need an automated way of extracting the original Long File Names from the hard drive and then renaming the 8.3 files/folders. Something like a hybrid of a file recovery program and a bulk file renaming program.

Report •

January 10, 2009 at 13:40:14
You might consider installing norton utilities and running norton disk doctor (NDD). It's better than scandisk at correcting problems and may allow you to recover the LFNs.

FAT16 versions of norton utilities had an UNERASE command but I'm not sure if versions for FAT32 have it. But if so maybe you can delete a file and see if recovering it will also recover its LFN.

Report •

January 10, 2009 at 16:23:34

I don't suppose now is a good time to mention the importance of regular backups.

Report •

Ask Question