Blog

1 2 3 Next
April 21, 2010 at 13:09 PM by Geediu Jing

JSON is built-in starting with PHP 5.2.  For me running 5.1.6 on CentOS, I needed to install the JSON extension in manually:

# yum install php-devel
# yum install php-pear
# pear install pecl/json

# cd /etc/php.d
# echo "extension=json.so" > json.ini
# service httpd restart

After that phpinfo() would output

json support     enabled
json version     1.2.1

 

Category: IT

January 26, 2010 at 16:34 PM by Geediu Jing

ESXi 3.5 does ship with the ability to run SSH, but this is disabled by default (and is not supported).

  1. At the console of the ESXi host, press ALT-F1 to access the console window.
  2. Enter unsupported in the console and then press Enter.
  3. If you typed in unsupported correctly, you will see the Tech Support Mode warning and a password prompt. Enter the password for the root login.
  4. You should then see the prompt of ~ #. Edit the /etc/inetd.conf file using vi.
  5. Find the line that begins with #ssh and remove the #. Then save the file. If you're new to using vi, then move the cursor down to #ssh line and then hit the x key to delete the #. Then press ESC and type in :wq to save the file and exit vi. If you make a mistake, you can press the ESC key and then type in :q! to quit vi without saving the file.
  6. Restart host or try doing a ps | grep inetd to find out the pid for it and then run the kill -HUP with the pid.

 

Category: IT

December 14, 2009 at 18:45 PM by Geediu Jing

Set up scheduled SMVI backup for my production servers last weekend and I kept getting E-Mail reports saying the backup failed on one of the VMs with the error message:

Creating a quiesced snapshot failed because the (user-supplied) custom pre-freeze script in the virtual machine exited with a non-zero return code.

A quick Google search once again saved the day - it turns out that the VM in question had problem getting a snapshot done in ESX and a quick workaround was to migrate this VM from one host to another (VMotion). After I did that I was able to perform an SMVI backup on that VM without issues.

Speaking of VMs it was "fun" last Thursday when one of the test server VMs crapped out on me and I didn't have a current SMVI backup for this VM. I ended up having to restore a copy saved in early September and the developers weren't really happy - but still better than having no database server.

All the problems started becase I was doing a DB restore and it ran out of disk space and somehow corrupted the MySQL instance. I tried to restart the mysqld service but it didn't like it. I restarted the VM and CentOS slapped me in the face with a kernel panic error. Kernel panic = geediu panic. The best way for me instead of trying to troubleshoot this problem was to simply restore from backup. Now I have scheduled a weekly SMVI backup for the test server VMs and a daily backup for the production servers.

 

Category: IT

December 10, 2009 at 15:28 PM by Geediu Jing

Got a call from a user asking me why her Outlook does not display any embedded pictures. When she forwarded the E-Mail to me I was able to view the embedded picture. I followed the advice from Microsoft, but the options were already set to show embedded pictures.

Instead of showing the embedded pictures it shows a red X instead. I did another Google Search and found a few solutions and they all point to the fact that the Outlook temp folder is filled with files and the folder requires clean up. Here's how:

  1. Exit Outlook (or make sure OUTLOOK.EXE does not show on Task Manager)
  2. REGEDIT and go to HKEY_CURRENT_USER\Software\Microsoft\Office\11.0\
    Outlook\Security\OutlookSecureTempFolder
  3. Find the value, which most likely points to something like
    %USERPROFILE%\Local Settings\Temporary Internet Files\OLKxxxx, where xxxx could be anything. Copy that value and open up a command prompt.
  4. In the command prompt, change to that directory and delete everything inside.
    I often tend to remove the directory alltogether and recreating a new one, for example:

RD %USERPROFILE%\Local Settings\Temporary Internet Files\OLKxxxx /S /Q
MD %USERPROFILE%\Local Settings\Temporary Internet Files\OLKxxxx

Now start Outlook again and try to view the E-Mail. The problem should be gone.

This folder should be cleaned up periodically if you ask me. In fact one really shouldn't even be using this folder to store these temp files (they are in fact just copies of the attachments you tried to open in Outlook or embedded pictures). Now that you know the registry key to change the value of this folder location, I'd actually recommend everyone to change the value from this inconvenient location to just, say, %USERPROFILE%\Local Settings\TEMP.  We IT folks always know to go in the TEMP folder of the user profile and clean up files periodically so why not store the Outlook temp files here as well.

Category: IT

October 19, 2009 at 0:46 AM by Geediu Jing

Had my Dell Inspiron 700m running Vista for over a year and I found it very sluggish. I was convinced that my laptop is going to run faster with a Windows 7 upgrade so I set out doing a Vista->Win7 upgrade this weekend.

Click to see full image

Notes:

1) Don't need to run the Upgrade Advisor - when you choose to Install, it does it anyway so it would save you a bunch of time.

2) Update your Intel 2200BG wireless card to the latest driver first and uninstall the Intel PROSet Wireless software because you won't be need it in Win7.

3) Uninstall any apps that you don't need or apps that can be easily reinstalled later. I had to do it because I had very little free disk space left. For my upgrade it reported that I need at least 16GB of free disk space.

4) Tons of people have problem getting the video adapter to work. The sad thing is that neither Intel nor Dell has Win7 driver for this adapter. Vista has the driver built-in and during the initial setup phase it did not complain about the adapter being a problem.  If you run into problems getting your video adapter to work follow the steps below (I am going to save you countless hours of trial and errors following reports from others on forums etc when you Google search):

 

  • - Save a copy of your Intel 855 video adapter Vista driver (or use this version here)
  • - Run command prompt as administrator
  • - Run the following command:   bcdedit /set nointegritychecks on
  • - Reboot into Safe Mode
  • - Update/install the Vista driver over the existing Standard VGA one
  • - Reboot to Normal Mode
  • - Do not log on - rather, use another computer to log on to the 700m remotely (RDP) - don't forget the /console or /admin switch.
  • - Run Device Manager (devmgmt.msc) and now you will see that two instances of "Intel(R) 82852/82855 GM/GME Graphics Controller (Microsoft Corporation - XDDM)" under the "Display adapters" section. They should both have the yellow exclamation marks on them. Now that this is confirmed, you can Ctrl-Alt-Del from your Inspiron 700m and log on. Once you have taken over from the remote desktop, you can shut down Windows 7.
  • - After the laptop is shut down gracefully, power it back on. That's it! You should now have a working installation of Windows 7 running 1280 x 800 resolution, completed with Sleep and Hibernate commands.

 

 

Category: IT

September 1, 2009 at 2:10 AM by Geediu Jing

Today I came across a problem with a client's XP workstation - it got really sick and started throwing up pop-ups LOL.  First thing I did was to perform a system restore to a few weeks back. After reboot the OS started giving me error messages and it stopped knowing how to handle .EXE files. I was not able to run anything except in a command prompt window. I managed to install and ran Spybot S&D and found a ton of mal-ware (ZEBO among them); Spybot S&D cleaned them all up nicely and I went and reboot. After reboot the problem with running .EXE files did not go away. I went through the registry and didn't find anything else wrong so I know this must be some type of registry corruption due to the mal-ware I've just cleaned up.  I ran a Windows XP repair and in the middle of the GUI set up it started complaining about not knowing what to do with EXE files again?!? I had to click on cancel a couple dozen times to force the installation to continue. At the end I landed back on the Windows desktop but I am still unable to run anything.

Google searches tried:

  • "Choose the program you want to use to open this file" "regedit.exe"
  • "Choose the program you want to use to open this file" "explorer.exe"
  • "Explorer.EXE" "Application Error"

Going through about 20-30 results with no progress, until I found this page where it talks about my specific problem of .exe file association being corrupted. Jumping to another page gave me a link to download a .REG file which fixed the problem!

Learn something new every day...

Now let me go back and finish up the customer's PC... I've yet to install all the Windows Updates and IE8 upgrade... and then I can call it a night.

Category: IT

May 31, 2009 at 2:11 AM by Geediu Jing

Last week I had the opportunity to perform a hard drive upgrade a server running Micfrosoft Small Business Server 2003... NOT A SIMPLE TASK.

Background:

Server had 40GB drive, 8GB C: and 32GB E:. Both Simple volumes on a Dynamic Disk. SBS 2003 meaning it is running Active Directory. The 8GB C: is running out of room. The goal of this upgrade is to set up the new 250GB drive to have a 100GB C: and a 150GB E:.

When I tried to ghost, the server won't boot up with the new cloned drive. It says:

LSASS.EXE - System Error
Security accounts manager initialization failed because of the following error:
Directory Services cannot start. Error status 0xc00002e1.
Please click OK to shutdown this system and reboot into directory services restore mode,
check the event log for more detailed information

I tried to boot up the server to the DS restore mode as instructed, but after logging on it logs me off right away without doing anything. I was stuck.

Googled the error message and looks like the problem had to do with the fact that ghost did something weird that I cannot explain (at the time) to the drive/partitions. After many trials and errors which I won't go in the details and which led me to no success, I realized how stupid I was not taking advantage of the fact the original drive was set as a dynamic disk.

Turns out I didn't need to use any cloning tools; I could simply add the new 250GB disk in the server and let SBS do all the dirty work. I ran Disk Management and right-clicked on the new disk and convert it to a Dynamic disk. Now I am able to create a mirror with the original 40GB dynamic disk. It took about an hour and the new drive was mirrored. I turned off the server and removed the old disk, and booted the server back up. Voila - server booted up fine and I am logged in, 250GB drive running merrily...

Or is it...

I am still faced with the problem of C: running low on disk space. The mirroring worked because the two volumes C: and E: were, well, mirrored. The new volumes are still 8GB and 32GB respectively. I also then realized why the ghost method was giving me problems when I booted up the server. During ghosting I asked the tool to automatically resize the partitions on the destination disk. The fact that C: and E: were resized on the 250GB after cloning was probably the reason why the server threw a fit when it was boot up.

In Disk Management I could extend my C: volume using the remaining disk space but that is just not a very good way to set it up, and I also want to be able to just use ghost to clone the drive later on. I have Acronis Disk Director but it does not support resizing of dynamic disks. I gotta figure out how to get rid of the dynamic disk setup.

Found a way after some short Googling, and seems that people out there have lots of success with this hack. I even found a link that takes me to a Microsoft support page that describe this hack so it is not so undocumented afterall. It involves simply changing the partition type from 42 (Dynamic Disk) to 07 (Basic Disk).  I didn't have DSPROBE but I have Acronis Disk Director so I used theboot sector editor tool that came with it. The Acronis tool doesn't see the contents of the dynamic disk but once I made the change of partition type in the boot sector editor, it was able to recognize the two partitions C: and E: in the now basic disk.

I rebooted back to Windows and made sure it booted okay, and I ran Disk Management and all seemed okay, C: and E: PARITIONS alive and well on what used to be a Dynamic Disk, now a Basic Disk. After this low-risk boot sector hacking exercise, I was able to go back to my Acronis Disk Director tool to do a resize of C: and E:.

Category: IT

April 2, 2009 at 17:58 PM by Geediu Jing

 



I came across an E-Mail that talks about some free tools from SolarWinds. One in particular monitors ESX servers. I thought I'd give it a try.

After setting it up on my VCenter box I quickly discovered that SNMP on my ESX box is not turned on. A quick Google search leads me to a blog entry that shows me how to enable SNMP. I also quickly realized that blog is affiliated with SolarWinds.

Anyway the quick dashboard-style monitoring tool is neat looking and does the simple job well. I have 3 ESX boxes but only one box for production (the other two are for testing) so the free version of this tool is good enough for me.

 

 

Category: IT

March 24, 2009 at 18:10 PM by Geediu Jing

More freebies... "undiscovered" downloads and services collection compiled by PC World:

http://www.pcworld.com/article/161674/101_undiscovered_freebies_the_list.html

Out of the 101 on the list, I only use OpenOffice.org, Defraggler, Dropbox... but I find it hard to believe that they would consider OpenOffice.org to be in the undiscovered category...

 

 

Category: IT

March 9, 2009 at 14:58 PM by Geediu Jing

I found out this morning that I can have my old Office 2003 menu bar back in my Office 2007 apps... sort of... thanks to the guys at Ubit. They've written UBitMenu, that places the classic Office 2003 menu in as a new ribbon in any of the Office 2007 apps.

Apparently UBitMenu has been out for a while but just recently they have translated it to other languages including English.  It works as an Office Add-In and they say there is no impact on performance. It's a freeware protected by a Creative Commons License (CCL).

I've installed it this morning and I urge all of you Office 2007 users to give it a try. I miss the menu bar and now it's back in as a ribbon. Talk about best of both worlds.

UBitMenu Download, license
The How-to Geek

 

Category: IT