Category Archives: Configuration

Execute denied for sp_send_dbmail

My backup email error handler noted a few errors in the windows event viewer, the specific error was

The EXECUTE permission was denied on the object ‘sp_send_dbmail’, database ‘msdb’, schema ‘dbo’.

If you have receieved this, then you need to add the user to the database by going to properties of the user and editing the “mapping” ensuring that said user is ticked next to the db “msdb”
Then run the follwing trasact against he msdb daabase replacing the word user here with the user you need to apply this to.

Offline Files and Folders not indexing or saving

Your are wondering why you cant add offline files to your seach index

When you look at your indexed locations and hover over your offline file locations you see the tooltip

indexing of offline files has been dsabled by your systems dministrator

or words to that effect

This implies that there is a policy restricting indexing of offline files being applied either locally or from the Domain Controller the computer is registered to (if at all).
Get your admin to check the group policies applied locally and from the DC, paying particular interest in the location
Computer Configuration/Administrative Templates/Windows Components/Windows Search

Ensure “Disable indexing of offline files cache” is not configured.

Another problem i encountered was, offline folder changes were not working, MS Excel and Word was hanging when trying to save to an offline location, yet notepad could happily save a txt doc to the location.
As it turns out, its an NT authentication issue, if you are able, set the security on the root folder of the offline folder so that Domain Users have full control, cascade these permissions to all child objects and then try your tests with excel word and folder changes. This worked for me.

Add a non indexed UNC as a library

Add a non-indexed UNC as a library
===========================
1. Create a folder on your hard drive for shares. i.e. c:\share
2. Create another folder in the above share. i.e. c:\share\music
2. Link the Library to this folder.
3. Delete the folder.
4. Use the mklink in an elevated command prompt to make a symbolic link. Name the link the same as the folder you created above.
i.e – mklink /d c:\share\music \\server\music
5. Done. Now you have non-indexed UNC path as a library.

source here

SQL Server error full-text filter daemon

We recently migrated from SQL server 2005 to SQL Server 2008 Web edition on our hosted servers, amongst several issues that were faced was the full text search error

SQL Server encountered error 0x80070218 while communicating with full-text filter daemon host (FDHost) process. Make sure that the FDHost process is running. To re-start the FDHost process, run the sp_fulltext_service ‘restart_all_fdhosts’ command or restart the SQL Server instance.

So when you execute the recomended SP

you receive this error

Msg 30046, Level 16, State 1, Procedure sp_fulltext_service, Line 163
SQL Server encountered error 0x80070218 while communicating with full-text filter daemon host (FDHost) process. Make sure that the FDHost process is running. To re-start the FDHost process, run the sp_fulltext_service ‘restart_all_fdhosts’ command or restart the SQL Server instance.

what you need to do is add the log on user the full text search service is running under, to the full text search security group on the box in question, it will look something ike this

SQLServerFDHostUser$lce-1$MSSQLSERVER

For me all i needed to do was add the “local service” account to the group – restart the sql service and re run the execute command

Problem solved

Diagnostics.PerformanceCounter Input string was not in a correct format

when you try to get performance information you receive the following error at the initialiser

Dim Ram As New Diagnostics.PerformanceCounter(“Memory”, “Available MBytes”)

Input string was not in a correct format

Starting “perfmon” from your run box to open the performance monitor presents you with a message box

—————————
Performance Monitor Control
—————————
Unable to add these counters:

\Memory\Available MBytes
\Memory\% Committed Bytes In Use
\Memory\Cache Faults/sec
\Memory\Cache Faults/sec
\PhysicalDisk(*)\% Idle Time
\PhysicalDisk(*)\Avg. Disk Queue Length
\Network Interface(*)\Bytes Total/sec
—————————
OK
—————————

Easy fix, you need to rebuild your performance counters. I copied c:\windows\system32\PerfStringBackup.ini from a machine whos counters were working, replaced the one on the broken machine. Open a command prompt, navigate to the same location and run the following

lodctr /R:PerfStringBackup.INI

This will reload your counters

If that fails try what microsoft suggest Here

Access to the registry key ‘Global’ is denied

If you use performance counters in web based apps you may end up running into this problem,

[UnauthorizedAccessException: Access to the registry key ‘Global’ is denied.]

UPDATE For IIS7 on windows server 2008 (see the end of this post)

The solution is pretty simple, originally posted here

How to Read Performance Counters Without Administrator Privileges [Ryan Byington]
If you have ever tried to read performance counter data on a Windows 2003 machine as a non admin user you will have likely seen an exception like the following:

System.UnauthorizedAccessException: Access to the registry key ‘Global’ is denied.
at Microsoft.Win32.RegistryKey.Win32Error(Int32 errorCode, String str)
at Microsoft.Win32.RegistryKey.InternalGetValue(String name, Object defaultValue, Boolean doNotExpand, Boolean checkSecurity)
at Microsoft.Win32.RegistryKey.GetValue(String name)
at System.Diagnostics.PerformanceMonitor.GetData(String item)
at System.Diagnostics.PerformanceCounterLib.GetPerformanceData(String item)

Windows 2003, Windows XP x64 Edition, and Vista require that the user be part of the Performance Monitor Users group to read performance counter data. Simply adding your non admin user to this group will fix this problem.

Accessing counters remotely is another story though. On Windows 2003, Windows XP x64 Edition, and Vista you still must be part of the Performance Monitor Users group on the remote machine but there is a problem with the PerformanceCounter class where it tries to read some registry keys on the remote machine that a non admin users do not have access to. To give your user read access to these keys without having to be an admin on the remote machine complete the following steps on the remote machine:

Open the Registry Editor by going to the Start Menu and selecting Run…, then type “regedit”, and click the OK button.
Navigate to the HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurePipeServers\winreg registry key.
Right click on the “winreg” key and select Permissions. Add users or groups to which you want to grant Read access.
Exit Registry Editor and restart Windows.
For more explanation on this process see here

UPDATE For IIS7 on windows server 2008 (16/11/2011)

This I can’t believe but none the less this is the way it is for IIS7. when you have performed the above steps and you are still receiving the error

Access to the registry key ‘Global’ is denied.

What you need to do is add the App Pool that your web app is running in to the “Performance Monitor Users” group as well. One immediate point is that you cannot find the group within the advanced search when adding objects to the group. You will have to manually type the name of the App Pool following this format

IIS APPPool\DefaultAppPool

Seems ridiculous I know and I haven’t fully got to the bottom of why but I suspect it is most likely something to do with the structure of IIS7 from an NT authentication perspective.

This also now puts an additional rule that one must not rename the App Pool and one must also be vigilant in as much as if you add another web app, creating a new app pool you might need to add this app pool to the group as well.

This updated solution came from here

Vista Boot – Element not Found

I recently had an enquiry from a user, they wanted to reclaim a partition on their machine that was allocated to emergency recovery. Seeing as the OS was different to that of the recovery I agreed.
My mistake was not to reconfigure the active primary partition. This caused the error msg Cannot find operating system.
So using the vista CD i booted in to restore mode and attempted to reconfigure the boot record, only to be presente with the message “element not found”. A quick google search yielded the solution. thanks goes to tturrisi for his accurate step by step recovery.

Excellent solution originally found here

Repair Vista Boot Loader
——————————————————————————–
If dual booting Windows & Linux, and also use GRUB, if you remove the Linux partition(s) you probably can no longer boot Windows. While this is very easy to fix if the Windows operating system is XP or earlier, it is a bit more complicated (but still easy to do) in Windows Vista.

More often than not, when removing Linux partitions in a dual boot Vista-Linux environment, or when using GPARTED to resize partitions, Vista can no longer boot.

Windows Vista uses a different boot loader than earlier versions of Windows. Fortunately the Vista bootable DVD contains a utility for repairing the MBR and boot sections of the hard drive. To repair the Vista bootloader: http://support.microsoft.com/kb/927392

However, the utility mail fail on any action and give an error message of “Element not Found”. This is because resizing the Vista partition(s) or Linux partition(s) changes the disk’s file allocation table and the Vista partition may get marked as “inactive”. The same holds true when removing or resizing Linux partitions. A boot partition MUST be marked as “active” to be bootable.

The remedy for “Element not Found” is this:

1.Put the Windows Vista installation disc in the disc drive, and then start the computer.
2.Press a key when you are prompted.
3.Select a language, a time, a currency, a keyboard or an input method, and then click Next.
4.Click Repair your computer.
5.Click the operating system that you want to repair, and then click Next. (if no Vista operating system is listed, click Next anyway)
6.In the System Recovery Options dialog box, click Command Prompt.

Next:

At the command prompt, type diskpart.
This will get you to the DiskPart prompt, which allows you to use a variety of hard disk partitioning and formatting tools similar to FDISK in older versions of Windows.

At the DiskPart prompt, type select disk # where the # sign is the number of the hard disk drive with Vista installed on it. If your Vista drive is the only hard drive in your computer, it is Disk 0.

Select the partition by typing select partition # where the # sign is the partition that has Vista installed on it.

Type active and press ENTER. The Vista partition is now active. Finally, type ‘exit’ to close DiskPart. Reboot the computer using the Vista dvd and follow steps 1-6 above. You can now repair the Vista boot:

Fix the Master Boot Record: (commands)

bootrec /fixmbr
bootrec /rebuildbcd
bootrec /fixboot

Symantec Antivirus DWHxxxx.tmp Bogus Trojan Horse

Recently one of my users had thousdands and thousands of files in the quarantine
All of them aparently trojan horse risks
All the files began with DWH ending with .tmp
This is infact symantec live update wizard DWHWIZRD.EXE trying to download updates available for the symantec application group rather than obtain the latest virus update list.

In doing so the real time scanner Rtvscan.exe identifies the temp file as a trojan, so depending on the rules in the risk settings will depend on what should happen when risks are found, it either deletes the file or quarantines it, and low and behold the update wizard starts to download the file again.

To resolve the issue (this time), login as an administrator of sorts be it domain or local. Locate the symantec liveupdate folder typically %system%\progam files\symantec\liveupdate and run the LUALL.exe
This will kick off the live update manually, follow the wizard steps until its complete then reboot.

This will likely happen again in the future until symantec either come up with a solution in one of the updates.

Note: this only appears to happen to users that are not part of the “local admin” group of the pc in question.

bb handheld update error

If you have an enterprise activated device and you want to update the handheld software, you might bump into this little error

You cannot update your software using this system as your device is currently activated on BlackBerry Enterprise Server or BlackBerry Professional Software. Please contact your administrator for updates. Or check for updates from your carrier service provider

you have two choices
1. remove the it policy on the handheld
2. edit the it policy on the BES to allow non enterprise upgrade (this does lead to reactivation)

I opted for option 2 since i manage our BES server. those of you who opt for option 1 need to continue googling

So for option two.
1. we edit the policy on bes Refer to instructions
2. Roll the IT policy back out to the device from the bes manager
3. Reboot the device
4. download the latest handheld firmware to your pc one size fits all
5. install the latest firmware package on your pc
6. remove the vendor.xml (C:\Program Files\Common Files\Research In Motion\AppLoader)
7. run the loader.exe and upgrade the devices firmware (C:\Program Files\Common Files\Research In Motion\AppLoader)

updating firmware on bb device
updating firmware on bb device

Finally
8. reactivate the device to rejoin it to the bes

and your done