Jump to content

Recommended Posts

Posted (edited)

Having trouble getting this F: partition to shrink, the drive is a partition on the server and only holds file shares, it's not an OS volume, so no other programs or system files.

 

SHRINK.jpg

 

It is 565GB and has 254GB free space... :confused: However shrink fails with the error message and Event Viewer (confusingly says it 'Error: during volume shrink initiated on volume ( F: ) we failed to move a movable file extent').

 

Unfortunately the file is a '::$DATA' file, so more of an NTFS file than a file in the share that I could just delete...

 

I've done all sorts of Windows Defrags and Disk Check with all sorts of /switches and in the GUI and CMD, but it won't sort itself out.

 

I need this space freed up for some further work I have to do this weekend (without users on the server) and it's stopping me moving forward.

 

Question is, as I guess I'm going to have to use 3rd party defrag software, what do you trust (not to mess it up or install other dodgy things)... also without boot time input as I'm working remotely?

Edited by Koldov
Posted (edited)

Normally that’s something like shadow copies or page files (virtual memory) that can’t be moved (if it’s a data file as mentioned)

 

Best test is to disable both, restart the server so it removes any file like that, and try again. Then re enable it once it’s shrunk

 

Steve

Edited by Steve21
  • Thanks 1
Posted
Normally that’s something like shadow copies or page files (virtual memory) that can’t be moved (if it’s a data file as mentioned)

 

I'd read a few suggestions about page files, hibernation files and such but they aren't enabled (I thought they might not apply since it's a file share, not an OS partition?).

 

I haven't enabled shadow copies/system restore etc.

Posted
I had this recently with the database drive on my old Exchange server. Shadow copies wasn’t enabled, but checking the VSS settings for that drive showed a single recovery snapshot. I deleted that via the command line and I could then defrag and shrink the volume.
  • Thanks 1
Posted (edited)

Pretty sure it's nothing like that (could be wrong obviously), there aren't any OS or program files running on there.

 

Worth checking though, how do you look for that?

 

Think it's just a very old 300GB file share that's never been defragmented properly (it does have an 'optimise' scheduled task set, but even when I did that manually it said it had never been run)...

 

Thing is there's obviously some kind of issue, because when defrag begins it says 7% defragmentation and then 0% when it's finished, then if I do it again it's back to 7%... :doh:

Edited by Koldov
Posted
As Steve said, check where your swap/page file is saving to, but the correct solution is to migrate to ZFS and save yourself the NTFS pain.
Posted
Having trouble getting this F: partition to shrink, the drive is a partition on the server and only holds file shares, it's not an OS volume, so no other programs or system files.

 

[ATTACH=CONFIG]67888[/ATTACH]

 

It is 565GB and has 254GB free space... :confused: However shrink fails with the error message and Event Viewer (confusingly says it 'Error: during volume shrink initiated on volume ( F: ) we failed to move a movable file extent').

 

Unfortunately the file is a '::$DATA' file, so more of an NTFS file than a file in the share that I could just delete...

 

I've done all sorts of Windows Defrags and Disk Check with all sorts of /switches and in the GUI and CMD, but it won't sort itself out.

 

I need this space freed up for some further work I have to do this weekend (without users on the server) and it's stopping me moving forward.

 

Question is, as I guess I'm going to have to use 3rd party defrag software, what do you trust (not to mess it up or install other dodgy things)... also without boot time input as I'm working remotely?

 

Have you tried doing a DISM clean up / health check

 

Also you could use processes explore from sys internals and see what is using that file , I’m guessing it’s most probably the system but might give you more info

 

Just a thought…

  • Thanks 1
Posted
Pretty sure it's nothing like that (could be wrong obviously), there aren't any OS or program files running on there.

 

Worth checking though, how do you look for that?

 

Think it's just a very old 300GB file share that's never been defragmented properly (it does have an 'optimise' scheduled task set, but even when I did that manually it said it had never been run)...

 

Thing is there's obviously some kind of issue, because when defrag begins it says 7% defragmentation and then 0% when it's finished, then if I do it again it's back to 7%... :doh:

 

On the disk Properties / Shadow Copy tab.

  • Thanks 1
Posted (edited)

No real update unfortunately...

 

Various culprits from Event Viewer appear like this:

 

Error: during volume shrink initiated on volume DISK2 ( F: ) we failed to move a movable file extent.

 

Diagnostic details:

- The last unmovable file appears to be: \Random Folder\Random File.JPG::$DATA

- The unmovable cluster of the file is: 0x74d619d

- Shrink potential target (LCN address): 0x7477300

- The NTFS file flags are: ----D

- Shrink phase:

 

To find more details about this file please use the "fsutil volume querycluster \\?\Volume{9654834e-78fe-11e4-80bb-549f35045c60} 0x74d619d" command.

 

Once that file is deleted it just picks another one... I did about 10 and then got to this one... "\$BitMap::$DATA" - (which just isn't going to get moved by Windows and might even be dangerous to move considering it's the map of where all the files are in NTFS) ...and then I gave up.

 

So without wanting to install and try out various random 3rd party boot time defraggers or partition software with all the potential issues and everything they come with... I've seen something bootable such as GParted suggested, but I haven't been able to determine if it's RAID friendly or if it will be too aggressive with delicate Windows NTFS files.

 

I am wondering if I can delete the partition, recreate it with a smaller size and use a backup to restore all the files (and hope 300GB+ of file shares all restore perfectly with all permissions intact etc).

Edited by Koldov
Posted

I don’t know if it’s something to consider or it would even work

 

But what about an xcopy of a directory that has nothing in it

 

Example of command below

 

robocopy /MIR c:\emptyfolder D:\ (drive your trying to remove data from)

 

 

??

 

Like I say don’t know if it would work again try at your own risk

  • Thanks 1
  • 3 weeks later...
Posted

Thanks all for the suggestions, sorry for the late reply...

 

I had a bit of a nightmare with Robocopy's 'infamous' MIR switch... (don't use it to copy anything to a drive with any other files/folders on... ask me how I know)...

 

In the end I waited for half-term I did a full back-up and then also copied the whole thing off to a USB using an old school piece of software, I'd forgotten about 'File Server Migration Wizard' form MS (which took about 8 hours)... but it keeps all the share permissions and copies them all back (which took another 8 hours).

 

Then I wiped the drive, made a smaller partition and put it all back.... It's a little more complicated than that as I had to deal with a few hundred 'long file path' files and other things, but it worked out OK in the end....

 

However.... I had the bright idea of painstakingly going through the vast majority of the folders and removing stuff from previous years (2017 videos of school play etc.) and I might have been a little brutal, but I looked if the last accessed date was over 2 years and moved about 140GB worth of 'stuff' off to the new 'Archive' partition... Year group folders that have the same thing and put into new folders (slightly modified) going back to 2016!!!!

 

What a mistake! Since they came back I've had nothing but moaning from admin and SLT about how they were going to use photos from 2010 and planning from 2014 and a folder that I've been informed isn't used anymore but there are some resources they might need... :doh:

 

I mean, I do get it (I've got usb drives full of folders of stuff that I will probably never use again), but what a pain... backups are huge, everything takes forever to move about on the server and nobody will ever look at 90% of this stuff again!

 

Trouble is, it would take weeks/months to dissect every file in every folder and decide what to keep, I'd like to give them access to it, but I know they'll just copy everything back, so in the end I walked out of the office and said I'll just move everything back myself...

 

Well, that was at least 3 nights worth of work down the drain...

 

:getmecoat:

Posted
the correct solution is to migrate to ZFS and save yourself the NTFS pain.

Sorry to do the 'told you so thing': With ZFS you'd simply diff against an old snapshot and restore the files using the output of the two snapshots. You could probably do it in a single line.

 

Alternatively, if you scripted moving the files off the filesystem you would have been able to generate a log of what you moved so you could use the script to move them back.

 

Sorry again for being captain hindsight, but I've made similar mistakes as this and learned from them so hope you will :)

  • Thanks 1
Posted
Thanks all for the suggestions, sorry for the late reply...

 

However.... I had the bright idea of painstakingly going through the vast majority of the folders and removing stuff from previous years (2017 videos of school play etc.) and I might have been a little brutal, but I looked if the last accessed date was over 2 years and moved about 140GB worth of 'stuff' off to the new 'Archive' partition... Year group folders that have the same thing and put into new folders (slightly modified) going back to 2016!!!!

 

What a mistake! Since they came back I've had nothing but moaning from admin and SLT about how they were going to use photos from 2010 and planning from 2014 and a folder that I've been informed isn't used anymore but there are some resources they might need... :doh:

 

 

We’re getting a little off topic now but i see a couple of ways to go about this

 

1) play the gdpr card - you can’t keep photos and data Indefinitely blah blah blah.

 

2) last big server refresh we did in a trust, all the old staff share was placed in a read only ‘archive’ folder. Staff were given a deadline to copy any important files to the new location. This puts the onus on staff to action it. We did have the backing of the trust iT lead tho.

 

The danger is people will actually just copy EVERYTHING back. But I’d be surprised if that happened.

  • Thanks 2
Posted
However.... I had the bright idea of painstakingly going through the vast majority of the folders and removing stuff from previous years (2017 videos of school play etc.) and I might have been a little brutal, but I looked if the last accessed date was over 2 years and moved about 140GB worth of 'stuff' off to the new 'Archive' partition... Year group folders that have the same thing and put into new folders (slightly modified) going back to 2016!!!!

 

What you do is slowly shrink the resolution of items over time. That 4k image from years ago, is only only 1080p etc :p Massive storage savings, without any real noticeable impact, even if users do access it years down the line.

 

We have both image and video shrinking setup that I run once a year for anything over a certain age. That way it doesn't remove them, but it saves lots! Win win

 

Steve

  • Thanks 1
Posted (edited)
We’re getting a little off topic now but i see a couple of ways to go about this

 

1) play the gdpr card - you can’t keep photos and data Indefinitely blah blah blah.

 

2) last big server refresh we did in a trust, all the old staff share was placed in a read only ‘archive’ folder. Staff were given a deadline to copy any important files to the new location. This puts the onus on staff to action it. We did have the backing of the trust iT lead tho.

 

The danger is people will actually just copy EVERYTHING back. But I’d be surprised if that happened.

 

I'd say point #1 is key here (though fwiw, also did point #2 with some success myself) - do they really have documented permission from everyone in the photos from 2010 to use their likeness indefinately? Is there any old PII from former staff or students from 2010 or earlier in this data? Do you not have a policy on data retention?

Edited by Roberto
Posted
We’re getting a little off topic now but i see a couple of ways to go about this

 

1) play the gdpr card - you can’t keep photos and data Indefinitely blah blah blah.

 

I'd say point #1 is key here

 

Can anyone give me chapter & verse on this (although a truncated version would be appreciated - my audience has a limited attention span when these things are mentioned)...

 

Photo/Video of a person in a 'public place' (if schools are classed as such a thing) etc...

Posted
Although I have mentioned the fact that as it is such a dumping ground without any real 'proper' structure, nobody can actually be sure what data is actually stored on there (I'm presuming ignorance is no excuse)...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...