NTBackup

Customer has an Exchange 2007 box that they wanted backed up, but didn’t want to pay for any extra software. Yay.
Set the NTBackup to the First Information Store of the exchange server, did a test backup, and away I went.

Fast forward 2 weeks and now it’s no longer backing up anything worth while. No error from the script either, so I had to dig through the event viewer logs and NTBackup logs (eventvwr, and C:\Documents and Settings\Username\Local Settings\Application Data\Microsoft\Windows NT\NTBackup\data)

“Registry Writer” has reported an error 0x800423f4. This is part of System State. The backup cannot continue.

Awesome.

I had previously selected System State AND Exchange’s store to be backed up. As restoring the system state has never yielded me great results (almost a waste of time. almost.) I decided to just uncheck the system state box and only backup Exchange’s Store.

Ran the backup again – this time success.

Outlook Cached, No New Emails

Customer was upgrading from Exchange 2003 to Exchange 2007. Installed Windows Server 2003 Enterprise x64 on a new server, ran all the updates, installed Exchange. Started migrating users over to the new server and no issues. Or so we thought.

A couple users had problems retrieving new emails in Outlook. Their iPhone/Blackberry showed the newest emails. Outlook web access showed the newest emails. Even Exchange 2007 showed DELIVERED for the new emails. The only solution to fix this problem at first:

Remove Cached Mode for Exchange
Remove the offending user’s shared mailbox
Magically Mail would start flowing after either of these two steps were done. However, since the problematic users were remotely located, cached mode must be used and the users required the shared mailbox.

The only users complaining had:

Cached Outlook Profiles
Other users mailboxes shared in their profile
Wireless connection to the network

First check (after making sure the email actually went through) was to look in ADSI Edit to verify that the users had proper permissions (you can also check on the client).

Start, Run
adsiedit.msc
Navigate to your Domain, and then your Users group.
Right-click on the user and select Properties
Make sure that homeMDB and homeMTA have your new servername in there

Second was to fix the OST file. We scanpst.exe (program files/microsoft office/office12/scanpst.exe) and repaired any errors.

Third was to start a new profile – we even tried on a test machine to be sure that it wasn’t a local issue.

Nothing worked. Final step (which worked) was to go to the following:

Open Outlook
Navigate to Tools – Account Settings
Click on your Exchange account and then click Change…
Click the More Settings… button
Click on the Advanced tab
Uncheck Download shared folders (excludes mail folders)
Restart Outlook

Windows 2k RDP Sessions

And here I thought I would be done with Windows 2000 Advanced Server. Oh well.
Basically you’re allowed 2 RDP sessions and 1 console (local) session on win2k server. Server 2003/2008 allow you to use all 3 sessions remotely, which is a definite plus. Easy way to get to the console session of 2003/2008:

Start, Run
mstsc /admin
IP or Name of your server

Easy way on Windows 2000. Uh, THERE IS NO EASY WAY.
Our situation:
2 Windows 2000 Advanced Servers
Located 120 minutes away
Not on the domain (workgroup)
One of the servers had the maximum number of connections
The other server we could login no problem

As long as you have rights (privs) to the admin share (c$) of the computer, you can very easily connect:
1.) I logged into the win2k server that still worked
2.) Pulled up the command prompt
3.) Typed qwinsta /server:192.168.20.150
4.) Typed rwinsta /server:192.168.20.150 sessionid

Basically qwinsta will query for all the active/disconnected RDP sessions on the server. Rwinsta will remove the session id you pick. Check out the picture for more information.

Then just connect as usual.

******EDIT******
OK, so sometimes I’m a little slow on the uptake. I forgot how to manage remotely without being part of the domain. Authenticate as a user on that system and you can do it all remotely – ie if BOTH of those servers had max connections, what would I do?

net use /user:usernamehere \\ip_of_the_server\c$
This will prompt you to enter a password for the username you selected
Now you can run the same commands above.

ALSO, it looks like you can use:
query session /server:192.168.20.150
and
reset session 36 /server:192.168.20.150
as those are easier to remember on new systems.

Daemon Tools and Threatfire

Daemon Tools would not run. I was receiving the error:

This program requires at least Windows 2000 with SPTD 1.60 or higher.
Kernel debugger must be deactivated

Awesome. And it was after I had installed Threatfire and then rebooted.
I tried setting TF to delayed automatic service startup, but still no dice.

Here’s the work around:

Hold Ctrl and right-click on the Threatfire icon in the taskbar tray
Select Exit
Windows Key + R, and type in CMD and hit enter
net stop threatfire
Load Threatfire by opening the program

Supposedly a temporary work around, but it’s been almost 6 months. Apparently you can also delay the startup by using WinPatrol.

Prevent Direct Access To PHP

Not sure if this is the correct way of doing things (as I’m still “learning” PHP), but it worked for me.
Basically I wanted to include a php file, but not allow the user to be able to directly go to that same file.

Example: index.php calls upload.php. Blocking the end user from going straight to upload.php (or even viewing the contents) would have been a bad idea.
This is running on a debian server with LAMP.

nano index.php

$including = true;

nano upload.php

if (!$including) exit(“Direct access is not permitted.”);

That’s it. Now navigate to upload.php and you’ll see it doesn’t allow it to work. Navigate to index.php and you’ll see the call still works. Great? Probably not, but it still works. Hopefully it doesn’t introduce any other bugs – but it’s a purely testing system anyway. So hack away.