Categories
blog howto windows

Uninstall Sophos Antivirus tamper protection lost password

How to uninstall Sophos Antivirus when the Tamper Protection doesn’t let you, and you don’t know the Tamper password.

  1. Stop the Sophos Anti-Virus service if possible. Open services.msc and stop the service.
  2. Open notepad with UAC elevation, run as Administrator.
  3. In notepad open the file “C:\ProgramData\Sophos\Sophos Anti-Virus\Config\machine.xml”
  4. Find the configuration section for TamperProtectionManagement

    <TamperProtectionManagement>
    <settings>
    <password>123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ</password><enabled>true</enabled>
    </settings>
    </TamperProtectionManagement>

  5. Change the password string (123456789ABCD… above is just an example, yours will be different.) to the new value: E8F97FBA9104D1EA5047948E6DFB67FACD9F5B73
  6. Start Sophos Antivirus or restart the computer.
  7. Disable tamper protection using the new password: “password” (without the quotes).
  8. Uninstall Sophos Antivirus.
Categories
blog exchange howto server windows

Exchange database dirty shutdown recovery JET_errLogFileSizeMismatch error -541

Warning: This is a technical article describing steps that you should only execute if you’re familiar and confident with the matter.

Error information:
Below is some error information that you might have seen and that’s why your search leads you here.

eseutil /ML “L:\Program Files\Microsoft\Exchange Server\V15\Mailbox\DB-MBX2\E02.log”
Extensible Storage Engine Utilities for Microsoft(R) Exchange Server Version 15.00
Copyright (C) Microsoft Corporation. All Rights Reserved.
Initiating FILE DUMP mode…
Base name: E02
Log file: L:\Program Files\Microsoft\Exchange Server\V15\Mailbox\DB-MBX2\E02.log
ERROR: Cannot read log file header. Error -541.
Operation terminated with error -541 (JET_errLogFileSizeMismatch, actual log file size does not match JET_paramLogFileSize) after 0.16 seconds.

eseutil /r “L:\Program Files\Microsoft\Exchange Server\V15\Mailbox\DB-MBX2\E02.log”
Extensible Storage Engine Utilities for Microsoft(R) Exchange Server Version 15.00
Copyright (C) Microsoft Corporation. All Rights Reserved.
Initiating RECOVERY mode…
Logfile base name: E02

Performing soft recovery…
Operation terminated with error -541 (JET_errLogFileSizeMismatch, actual log file size does not match JET_paramLogFileSize) after 0.31 seconds.

Solution:
If possible have a backup or a copy of the database before you manipulate it! Transaction log files are critical for the database, these are not just information files that you can delete!

If the DISK where the log files of your exchange database resides has run out of space you could find yourself with a corrupt log file. When you try to perform a soft recovery with eseutil /r and the path to your E0?.log (in my case E02.log) file you get an error about header information and size mismatch. The E0?.log file is the current transaction log file that Exchange was writing to when the disk ran out of space. This file is now corrupt and transactions in the file that were not applied to the database will be lost. All other older log files will have hexadecimal sequence to it such as E0?00E475A.log and so on. You can check which log files are required for the database to perform a soft recovery by reading the header information of the database in question as follows:

eseutil /mh “F:\Program Files\Microsoft\Exchange Server\V15\Mailbox\DB-MBX2\DB-MBBX2.edb”
replace path and filenames with your database

In the wealth of information returned you will see a line stating the state of the database, which will be Dirty Shutdown. (If it is Clean Shutdown than you do not need to perform recovery). Below the state is the line Log Required which shows the files needed.

Log Required: 190299-190336 (0x2e75b-0x2e780)

In my case the databases needs the files E020002E75B.log and newer on to E020002E780.log (this is HEX sequence). Older log files can be moved to a different hard disk if you need to free some space. Be careful, don’t delete, sorting these files in Explorer is not easy, you can’t do it by name because of the hex sequence and by date/time is not foolproof. So double-check or just expand the disk and leave all log files as-is.

Now to perform the recovery we have to move the corrupt E02.log file to a folder or other disk. Now that the corrupt file is removed and you are 100% sure that all the other required log files (see section above) are present we can perform soft recovery with the /a option to skip missing log files and bring the database back to a clean state.

eseutil /r /a E02 /l “l:\Program Files\Microsoft\Exchange Server\V15\Mailbox\DB-MBX2” /s “l:\Program Files\Microsoft\Exchange Server\V15\Mailbox\DB-MBX2” /d “F:\Program Files\Microsoft\Exchange Server\V15\Mailbox\DB-MBX2”
change the names and paths to your situation.

/r is soft recovery
/a is skip missing logfile
E02 is the base name of the logfiles, this is dependant of the database, could be E01, E02, E03 …
/l is for the log files location (where E02.log and other E02xxxx.log files reside)
/s is for the system files location (where E02.chk resides)
/d is for the database files location (where DB-MBX2.edb resides)

Output will be like this:

eseutil /R /a E02 /l “l:\Program Files\Microsoft\Exchange Server\V15\Mailbox
\DB-MBX2” /s “l:\Program Files\Microsoft\Exchange Server\V15\Mailbox\DB-MBX2” /d
“F:\Program Files\Microsoft\Exchange Server\V15\Mailbox\DB-MBX2”

Extensible Storage Engine Utilities for Microsoft(R) Exchange Server Version 15.00
Copyright (C) Microsoft Corporation. All Rights Reserved.
Initiating RECOVERY mode…
Logfile base name: E02
Log files: l:\Program Files\Microsoft\Exchange Server\V15\Mailbox\DB-MBX2
System files: l:\Program Files\Microsoft\Exchange Server\V15\Mailbox\DB-MBX2
Database Directory: F:\Program Files\Microsoft\Exchange Server\V15\Mailbox\DB-MBX2
Performing soft recovery…
Restore Status (% complete)
0 10 20 30 40 50 60 70 80 90 100
|—-|—-|—-|—-|—-|—-|—-|—-|—-|—-|
……………………………………………

Operation completed successfully in 3.635 seconds.

The database is now clean, you can check again with eseutil /mh as we did before and see the state listed as Clean Shutdown.

If you want to quickly clean-up logfiles no longer needed you should perform an Exchange aware backup. If you don’t have one and you understand the consequences you can enable circular logging on the database.

Good Luck!

Categories
blog howto windows

Microsoft Print to PDF empty 0KB file

If you create a PDF file using “Microsoft Print to PDF” and the file is corrupt and appears empty 0KB. Try to make the file again but don’t use “,” (comma) in the name.

Categories
blog exchange howto server windows

Outlook 2013 sync problems and message that Administrator has made a change

This post describes a problem I recently experienced when migrating from Exchange 2007 to Exchange 2013. Outlook 2013 clients would pop-up a message about the administrator making changes that require a restart of Outlook continuously. Also the folder synchronization fails and you see new messages arrive in your Inbox only to dissapear again after 1 second and then come back again and so forth.

The Microsoft Exchange administrator has made a change that requires you quit and restart Outlook

outlook error synchronizing folder [0-0]

These problems started occurring right after the old public folder database was deleted on the Exchange 2007 server. I only noticed it after I had already uninstalled the Exchange 2007 server completely. Why only Outlook 2013 has this problem I don’t know, but here is what’s wrong.

On the Mailbox database on your new Exchange server there is still a value pointing to the OLD public folder database that is now deleted.
You need to fix this using Adsiedit.msc:
Go to:

Configuration >CN=Services > CN=Microsoft Exchange > CN=Your Organisation > CN=Administrative Groups > CN=Exchange Administrative Group > CN=Databases

For each mailbox database, right click and check the attributes for “MSEXCHHomePublicMDB”. You will see that the value for this attribute points to “CN=Public Folder Database*,CN=Deleted Objects,CN=Configuration,DC=YourDomain,DC=com” the old object for the public folder database that has been deleted. You must clear this value using the clear button, so it changes to “not set”, just emptying the value won’t work. Restart the Information store service or reboot the Exchange server and the problem should be solved.

Categories
blog howto windows

Citrix client receiver error AllowHotkey

This problem can be solved by either disabling lockdown on the client or adding a registry key on the client for allowhotkey.

—————————
Error number 2320
—————————
Citrix online plug-in Configuration Manager: No value could be found for (AllowHotkey) that satisfies all lockdown requirements. The lockdown requirements in force may be conflicting.
—————————
OK
—————————

option 1 (disable lockdown)
HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Citrix\ICA Client\Engine\Lockdown Profiles\All Regions
Enablelockdown change to 0

option 2 add reg key for AllowHotkey with empty value
HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Citrix\ICA Client\Engine\Lockdown Profiles\All Regions\Lockdown\Client Engine\Hot Keys
“AllowHotkey”=””

Categories
howto windows

Windows 10 Upgrade error unable to install on partition

EDIT: I read somewhere that it needs 50MB of free space on the partition. Maybe you can first assign a drive letter using disk management and see if you can free up some space.

I had this “Something went wrong” & “unable to install on partition” error when I tried to upgrade a Laptop with Windows 7 Home Premium 64-bit installed. This laptop is from late 2011, and had Windows 7 pre-installed by the manufacturer.

This cryptic error, in my case, just meant that the hidden reserved system partition that Windows 7 creates on install was too small/full for Windows 10.

In earlier versions of Windows 7 this partition would be created with a size of 100MB. In Windows 8 I mostly see this partition with a size of 400MB.

So what to do? Expand this hidden system partition from 100MB to at least 400MB. To be safe for the future I expanded it to 800MB.
Now this is not something you can do from within Windows, because the C partition will have to shrink AND move to the right to make room to expand the system partition.

I suggest using a partition manager to do this. I had success using the free Minitool partition manager.
http://www.partitionwizard.com/free-partition-manager.html

First select the C partition and shrink by 700MB and move it to the right so that the free space comes available in between the small SYSTEM partition and the C partition. Then next select the SYSTEM partition and expand by 700MB until the free space is gone.

Now click the execute button, the software will tell you it must reboot to execute these actions.
Go ahead reboot, and then wait for some time (could take up to hours on big and slower drives) for the software to finish. You get a nice progress bar. For me it took 10minutes on an SSD.

When it’s finished it will boot Windows and you can check in Disk Manager if everything looks good. You can then uninstall or keep the software and start your Windows 10 Upgrade again.

Categories
blog howto windows

Windows 10 upgrade reservation notification icon not showing

Can’t See the Windows 10 Upgrade Notification?

How to display the Windows 10 upgrade icon if it is not visible:

I have seen the windows 10 upgrade notification appear on Windows 7 SP1 & 8.1 computer just fine.

Let me start out by saying this: “When the computer is joined to an active directory domain the icon will not show”. Not matter how hard you try to manually get it started by triggering the tasks or runing the GWX.EXE or GWXUX.EXE applications. It won’t work (for now?) on domain joined computers. Not even if you logoff and logon using a local administrator account.

When you remove your active Directory domain membership and put the computer in a workgroup you will see the icon after the reboot. You can then make your reservation, but I don’t think it will actually download the upgrade on July 29th if the computer is joined to the domain again, not sure about that.

If you’re a home user not connected to an active directory domain there are some things to check:
– You need to be on Windows 7 SP1 or Windows 8.1 Update1
– You need to have the KB3035583 update installed

If you still have trouble getting the icon you can try the BAT file created by a Microsoft Answers forum moderator.
https://www.dropbox.com/s/0u0au9xgy6ss18p/win10fix_full.zip?dl=0 (no need to register at dropbox just skip,
download and unzip the BAT file in the C:\TEMP directory (create dir if needed).
Open a CMD with administrative rights.. (right click on CMD icon in start menu and choose Run as Administrator)
CD c:\TEMP
win10fix_full.bat
Follow the instructions …

Categories
blog howto server windows

printer driver installation error 0x00000057

note: This is a technical article meant for system administrators or advanced users. Make backups of files or registry keys that you manipulate. Use caution and proceed at your own responsibility.

I ran into this problem after cleaning up printer drivers and manually cleaning up in the c:\windows\system32\spool directory.
When trying to connect to a printer on the printserver the error 0x00000057 would show. This error occurs when windows tries to install the printer driver.

If the driver is already present on the system, first try to remove the printer driver using the printserver properties (printui.exe /s /t2). http://support.microsoft.com/kb/2771931 After remove try again to install. If that didn’t work, or like me this particular driver was not installed on the system, read on.

If you have another computer or server that does install the printer without problem, than you can try this.
1) On the working computer open the registry editor and navigate to: (note for 32bit systems its slightly different)
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Print\Environments\Windows x64\Drivers\Version-3\
2) Find the key with the driver you need. Export this driver key to a REG file. Copy the file to the problem computer.
3) On the problem computer open the registry editor and check for the presence of the key, delete if present.
4) Import the REG file made in step 2 on the problem computer.
5) In the key note the value of the Infpath item. It’s the location of the INF file. We need the whole containing folder and items in it.
Should be something like: c:\windows\system32\DriverStore\FileRepository\xxx.inf-yyyyyy-zzzzz\
6) We need to copy this folder and its content to the problem computer. Not an easy task because of the permissions.
But you can do it like this from the working computer:
– Open an elevated command prompt (run as administrator CMD.exe)
– execute the following command: xcopy C:\Windows\System32\DriverStore\FileRepository\xxx.inf-yyyyyy-zzzzz\ \\problemcomputer\c$\Windows\System32\DriverStore\FileRepository\xxx.inf-yyyyyy-zzzzz\ /E /C /F /H /R /K /O
7) Now we have the registry key and the files present on the problem computer.
8) Restart the print spooler on the problem computer and try to connect the printer again or try to install the driver again.

0x00000057 printer driver installation error
source: https://social.technet.microsoft.com/Forums/itmanagement/en-US/a225d71c-be8b-4530-bf50-63001559a978/windows-can-not-connect-to-the-printer-0x00000057?forum=itmanager

Categories
blog howto

How to delete LinkedIn saved e-mail contacts

edit: Solution all the way at the end, skip to the direct link if you are thinking TLDR.

After receiving one to many e-mails from LinkedIn with the message that e-mail contact x had joined LinkedIn, I started looking for a way to delete these contacts or address book and stop receiving these mails. It turns out this is not as easy as you think.

Firstly disable the sending of these e-mails is not possible, it’s not listed on the options to opt-out of different kinds of e-mail communications from LinkedIn.
LinkedIn communication settings

If you read some posts on the internet everyone keeps reffering to https://www.linkedin.com/contacts/manage_sources/ but this only lists options to add sources for synchronizing, I had nothing enabled so I couldn’t disable anything. At the top of content it showed me the number of LinkedIn connections and I could click on that, but it showed me a list of my connections, even after changing the filters to saved contacts it didn’t show anything besides connections.
LinkedIn contact settings

So the wise thing to do is open a support ticket, and so I did but 5 days later the support person could only send me standard responses and did not really understand or read my question.
LinkedIn support ticket

SOLUTION: I then finally found the answer by accident after I was changing my profile information.
When you get to this page: https://www.linkedin.com/fetch/importAndInviteEntry it show at the top Manage imported contacts. And that brings you to this page: https://www.linkedin.com/people/contacts where you will see all your imported contacts and you can delete them all.

Finally, no thanks to LinkedIn support.

Categories
blog howto linux network server virtualization

Virtual Private Server on SSD storage

 Update: After reviewing the offerings, I’m no longer running my VPS at digitalocean. Instead I’m using Linode at the moment.
www.linode.com

Easily deploy an SSD cloud server on @DigitalOcean in 55 seconds.

Recently I read about the virtual private servers you can create on www.DigitalOcean.com. They call them Droplets, and they get created in less then a minute if you don’t enable back-ups, or just a couple of minutes with back-up service enabled. You can choose between different geographically located data centers. You can choose between New York, San Francisco, London, Amsterdam and Singapore. You get one public ip address (or ipv6 if you prefer, but who does anyway).

You can choose out of some pre selected minimal OS installations such as Ubuntu, CentOS, Debian, Fedora and CoreOS. Or you could even deploy your VPS complete with a LAMP (Linux, Apache, MySQL and PHP) or even with WordPress of Drupal setup. If I looked at the price (10$/month or 12$ with back-up) for a VPS, with 1 CPU, 1GB RAM, 30GB DISK and 2TB data transfer, and compared that to what I was currently paying for 2 shared hosting plans, the math was clear. For a bit less than what I was paying I get my very own Virtual Private Server where I can configure everything I want and have full rights on everything.

For me, as an enthusiastic system engineer, with experience on multiple Linux flavors, this was a very nice project. Starting from a minimal CentOS 7 installed Droplet, I quickly installed and configured Apache, Nginx, MySQL and PHP and started serving web pages. My first tests were a success. I configured different management tools and secured the system with a software firewall. Because your VPS has a public ip address you must think good about security. It took some time getting used to the new firewall software system in CentOS 7 called firewalld. After some cursing I had it set up as I wanted.

The next step was to migrate the first of my existing websites over to the new VPS. I chose to configure virtual hosts in an organized manner so that I could always expand to more websites if needed. After transferring the databases and website data, I set course for a new goal. Making my sites more secure by using HTTPS encryption on the login pages. By using the free 1 year class 1 certificates from www.startssl.com I did not have to make any extra costs. Update: Using Let’s Ecrypt now and HTTPS on all pages! After some hours of configuring and testing I had everything running smoothly. I migrated all the DNS records to my new VPS and shortly after my 1st website was running live on the new VPS.

My next goal was to set up mailboxes for every virtual host and using IMAP to connect to them. I choose POSTFIX as the SMTP server and DOVECOT as the IMAP server. POSTFIX was configured for using virtual mailboxes that don’t require a Linux user. DOVECOT was configured for SSL/TLS encrypted connections so password are never sent in clear text. To finish it off I installed ROUNDCUBE as a web mail solution.

After my successful first website migration the second one followed quickly and went smoothly as well. This time I also needed a FTP setup and I chose VSFTPD and again made it possible to use SSL encryption.

The VPS is now running all of my websites, except this blog.

PS: If you are wondering why I don’t migrate this blog, running on my home server, that’s because it’s a challenge to keep a website running on a homeserver with minimal hardware costs and dynamic internet ip address. It also has some other uses for me besides serving this blog.