Author Archives: amida168

adb Not Working in KitKat

After I got a LG F3 as a backup phone, I started to flash different ROMs for my HTC One X. One recent ROM I tried is KarbonKat. It’s based on CM11, which is a KitKat ROM. The ROM seems to be more stable than the official CM11 nightly that I tried earlier.

One thing I noticed is that the adb command stopped working after I flashed my phone with KarbonKat. My computer does not recognize my One X either. I tried to change the USB mode and finally got it to work.

Here is what I did:

  1. Tap on Settings.
  2. Tap on Storage.
  3. Tap on the settings icon (looks like 3 vertical dots) on the top right corner.
  4. Tap on USB computer connection.
  5. Tap on Media Device (MTP).

I then connected the phone to my computer and adb started to work again.

How to List Members in an AD Group

We need to list all the members in an AD group from time to time for review purposes. The commands are dsget and dsquery. A problem I had was that I could not remember the proper syntax for this, and every time I needed to use them, I had to look them up again. Here are the commands.

dsquery group -name "GROUP-NAME" | dsget group -members -expand

Replace the GROUP-NAME with your group name. For the first part, query the AD using the GROUP-NAME provided. Its output will be sent to dsget to list the members in the group.

Again, if you are interested in details of the commands, try the following.

dsquery /?

dsget /?

For other Windows command line tips, check out this highly recommended book: Windows Command-Line Administrator’s Pocket Consultant, 2nd Edition

Black Screen After Windows 7 Upgrade

We have been doing a lot of XP upgrades since January. One problem I encountered was with how the machine boots to a black screen after upgrading to Windows 7. There are quite a few articles on how to fix the problem. Here is a short list.

I have tried some of these suggestions, but they did not solve my problem. In the end, I replaced the video card, and I was able to get the machine to boot normally.

I ran into the same problem yesterday. However, I could not just replace the video card because this machine had a more powerful card for a certain program. I do not have a video card with similar specs as a replacement.

I tried to re-install the video card driver but to no effect. I tried to install the driver from the manufacturer’s web site; still, it did not work. In the end, I replaced it with a different card just to test. if It worked after the card was replaced. I then took the video card out and put the original video card in. To my surprise, the machine booted up just fine with the original card.

So, if you have this problem, besides trying out the suggestions in those articles, you can try to swap a different video card and then swap back to the original card and see if it works for you.

SeaTools DOS – Invalid Opcode Problem

I was working on a Dell Inspiron 1545 laptop. The computer crashed, and the OS was completely gone. I suspected it was a hard drive problem, so I ran Ultimate Boot CD and selected the SeaTools to test the hard drive. The SeaTools did not load at all, and I got the following error message: “Invalid Opcode at xxxx xxxx …”

I thought the problem might be because the version was an older version on the Ultimate Boot CD. I downloaded the latest version, and it did not help. I even downloaded the SeaTools from Seagate directly and made a USB stick with it. That did not work either; it produced the same error message.

Later, I learned that the problem was with the SATA operation mode. On this model, I had to set the SATA operation mode to ATA in order for the SeaTools to run. To change the settings, you need to enter the BIOS setup by entering F2 while the machine boots up. Note that the key to enter the BIOS setup might be different on your machine; consult the user manual for your computer for the correct key. Once in the BIOS setup, find the SATA operation and change it to ATA instead of AHCI. Save the changes and reboot. You should be able to run SeaTools now. Once you are done testing your hard drive, remember to enter the BIOS setup again and change the SATA operation mode back to AHCI. Otherwise, your computer may not boot at all.

Mac OS X Mavericks Network Issues

Some users reported networking issues on the latest Mac OS 10.9 Mavericks. I got this tip from my colleague, and it seems to fix the intermittent network problem.

The fix is to create or edit this configuration file /etc/sysctl.conf . Add or edit this line

If you are familiar with editing the configuration file using vi or emacs, this is all you need to know. If not, here are the step by step instructions:

  1. Open Terminal in Applications -> Utilities folder.
  2. Type this command to invoke pico editor. Enter your password to continue.
    sudo pico /etc/sysctl.conf
  3. Add or edit this line
  4. Press Ctrl+o to save the file. Press enter for confirmation.
  5. Press Ctrl+x to exit out of the pico editor.
  6. Reboot the computer.

If you are interested in the details about this change, please see this thread for more info.

How to Delete a Local User Using Command Line on Mac OS X

One user reported that she could not log on using her regular network account on a particular Mac computer. Her account worked on all other computers but not on this one computer. If we configured the login screen to list users, you could see that a local account by the the same name was listed. However, when we checked the System Preferences and tried to delete the account, the account was not there. We were therefore unable to delete the local user account.

This excellent post led me to resolve the problem. To search for a user, use this command.

/usr/bin/dscl . -search /Users name username

You can then use this command to delete the user.

sudo /usr/bin/dscl . -delete "/Users/username"

After I deleted this hidden local user account, my user could log on using her network account again.