UnitedForums - UK Web Hosting Forum UnitedHosting Community Hosting Forums
Network and Server StatusCustomer SupportUK Web Hosting
UnitedHostingUnitedHosting Sitemap UK Hosting ForumUK Web HostingWeb Hosting ForumsUK Reseller HostingWeb Host CommunityUK Managed Dedicated ServersHosting Help and SupportUK Domain Name Registration

Go Back   UnitedForums.co.uk > UnitedHosting Community > General Chat Lounge

Reply
 
Thread Tools Rate Thread Display Modes
Old 5th July 2008, 10:25 PM   #1 (permalink)
jmc
Registered User
 
Join Date: Jan 2004
Location: Hartlepool, UK
Posts: 155
auto-file deletion

Can anyone enlighten me as to the simplest way of providing this facility?
My local Photo Club has asked me to "spring-clean" their collection of XP PC's. The usual stuff... defrag etc. (There is no internet access on any of the machines, btw).
They currently allow users to store unlimited images on the machines, but are intending to apply some restraints on users by implementing an "Auto-Delete after 30 days" policy. I've already suggested that simply setting a disk quota may be better and told them how to set it up, and they had a look at it... but it appears the h/d's are set up as FAT32, not NTFS. The Quota facility doesn't play on FAT32. And I REALLY don't fancy re-formatting/re-installing half-a-dozen pc's next weekend!
So, basically, they want to schedule a check which will run on boot-up, check the "age" of all files in the various User folders and delete anything older than 30 days. I'm thinking... a vbs script run through the Windows Scheduler??? And that's about where I fall flat on my ass.
Can any kind soul help???
Cheers,
John Mc
jmc is offline   Reply With Quote
Old 6th July 2008, 01:00 PM   #2 (permalink)
pursuit
Registered User
 
Join Date: Feb 2006
Location: London, UK
Posts: 263
since you mentioned vbs so assuming you'd be comfortable with a bit of VB programming:

first, open the image/photo directory and read all photo files (except the two meta 'files: . & ..') in a loop, then check each file's last modified date, and if 30 days or over, then do a file delete. any basic VB tutorial book would have similar examples.
you then compile the vb program and make an exe file, add it to the windows startup list. everytime window starts, it will run the exe and do the house keeping automatically.

I dont think you can run a vbs script to do this kind of thing for it would be a huge security implication if vbs scripts is allowed to carry out this sort of operations(local file/disk operations).
pursuit is offline   Reply With Quote
Old 6th July 2008, 05:11 PM   #3 (permalink)
Alex.
Registered User
 
Join Date: Jun 2007
Location: UK
Posts: 107
Send a message via MSN to Alex.
Microsoft have produced a (free) tool called Steady State to make it easier to manage shared computers. It may not be quite what you're looking for, but I noticed it has a 'Disk protection' mode which allows you to set an auto delete setting which removes changes made to the computer every so often. Here's a screenshot tour Screenshot Tour: Kid-Proof Your PC with SteadyState And here's the product homepage Windows SteadyState
Alex. is offline   Reply With Quote
Old 6th July 2008, 11:41 PM   #4 (permalink)
knapper
Senior Member
 
Join Date: Jun 2006
Location: Co. Durham
Posts: 101
Quote:
Originally Posted by jmc View Post
I've already suggested that simply setting a disk quota may be better and told them how to set it up, and they had a look at it... but it appears the h/d's are set up as FAT32, not NTFS. The Quota facility doesn't play on FAT32. And I REALLY don't fancy re-formatting/re-installing half-a-dozen pc's next weekend!
You don't need to, using microsofts covert tool from the command line you can convert a FAT32 to a NTFS partition without losing the data. Obviously you need to make backups, just in case, and do a quick read up on the tool, but it appears reliable enough.

More information from Microsoft can be found here:

How to Use Convert.exe to Convert a Partition to the NTFS File System
knapper is offline   Reply With Quote
Old 12th July 2008, 05:17 PM   #5 (permalink)
jmc
Registered User
 
Join Date: Jan 2004
Location: Hartlepool, UK
Posts: 155
Thanks, lads! Those are a couple of really usefull toys. I'll be taking a good look at Steady State later.
So, OK... they've agreed to go the simple "disk quota" route. And to introduce some data security by having the Users' files being stored on a separate (D logical partition (already there).
I've created the required user accounts (36 of 'em... would you believe it - they were ALL logging on as Admin and saving files in sub-folders of Admin's My Docs ). And I've spent the last couple of days finding folders/files stuffed all over the damn place. Now, I'm trying to figure out the most efficient way of applying a new default User "My Documents" setup, which will put current and future Users profiles/docs straight into the D: drive, rather than into the usual C:\Documents and Settings...
Obviously, I'm exploring a variety of Registry hack here. I know I can log on as each individual User and "Move" the MyDocs target, but I don't really want to hand that routine off to the Club Committee. I think it's enough of a strain for them that they'll need to create New Users.
I've explored a variety of HKEY-CURRENT_USER/HKEY_LOCAL_MACHINE and HKEY_USERS/.DEFAULT options (done a LOT of Googling!), most of which involved editing the path to the Personal Shell Folders in a variety of ways. The only method which seems to work is editing the CURRENT_USER bits. But only (apparently) for whoever I logged in as! The setting doesn't propagate through for any other existing or newly created User.
Has anyone had any joy creating this kind of setup?
Sorry to waffle on... my head is in bits!
BTW... any of you lads are ever in Hartlepool, beer's on me!
John mc
jmc is offline   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


All times are GMT. The time now is 03:30 AM.

UK Web Hosting  |  UK Reseller Hosting  |  UK Dedicated Servers UnitedHosting  |  UnitedSupport  |  UnitedForums  |  SEO by vBSEO 3.0.0
Copyright © 1998-2008 United Communications Limited. All Rights Reserved. Registered in England and Wales 3651923 - VAT Reg No. 737662309