Posted by Jason Mohan on Jul 15th, 2009 | 0 comments

Have two versions of the same software that open the same file extension? Having trouble getting windows to open the right one. We had this same problem with Crystal reports (.rpt extension), but setting it in the file types options in windows did not work. However the bottom command worked in our citrix farm. Don’t put this is a batch file because the %1 doesn’t flow...
Posted by Jason Mohan on Jul 1st, 2009 | 0 comments

The following code will allow you to rename a file to the date and time. Save this code in a batch file (in this example we’ll call it rename_it.cmd), then call it with the file that needs to be renamed. You can also download it here, rename_it.cmd.
Example: rename_it FILENAME.txt
@Echo OFF
TITLE DateName
REM DateName.CMD
REM takes a filename as %1 and renames as %1_YYMMDDHHMM
REM
REM...
Posted by Jason Mohan on Jul 1st, 2009 | 0 comments

Recently I had to turning on auditing on a file server. However turning on auditing was fine but what to do with the logs. The max recommended size for logs are 65Mb. However within 4 hours I was hitting that 65MB limit, and my oldest logs would start erasing. There are some tools out there that can help you, but nothing beats building your own. While I was researching how to archive my logs in a...
Posted by Jason Mohan on Jul 1st, 2009 | 0 comments

Need to delete old files based on how old the file is? Need to do in a batch file? Well there’s a great program developed by these guys http://winhlp.com/node/386. Only thing is you need to have java loaded on the machine you are running the command from. The program is accessible via command line and all you need is the below command. The last number in the command is how many days old....
Posted by Jason Mohan on Jun 25th, 2009 | 2 comments

Got a print spooler that won’t start, or crashes everytime you start it. Well here’s a last resort fix that should bring it back up. However this will remove all printer drivers, print monitors, and printers off of the machine. If you are able to access the registry on the machine you can at least write down the name, share name, ip, and printer driver used for each of your printers...