Reset “lost” Administrator Password Mac OS X

Lost your administrator password?  Working with a client who has lost their administrator password and need to install applications and updates? Here is a very simple workaround to resetting the password on any account in OS X.

So what do we do?

Basically start up your Mac in single user mode, deleting the local profile cache for the creation of a new user.  Upon restart, you will be prompted to setup a new administrator account.   This process of creating this account is the same as after a fresh install.  Once you have logged in under the new account, open System Preferences>Accounts and change the password of your original account.  No data is lost, and nothing is deleted.  Logout/Login with your new password and then delete the temporary admin account.

Presto – Password recovered.

1.  Reboot in Single User Mode – hold Apple Key(command)-S after you hear the chime

2.  Run the following:

1
2
3
mount -uw /
rm /var/db/.AppleSetupDone
shutdown -h now

**Note**
In terms of security, this is why restriction of physical access to a machine is critical.  Passwords are not safe, and are not to be conceived as “safe”.  Strong passwords are irrelevant if you do not limit physical access to machines.  Play safe.

Read More

Grub2 – A beginners guide

Take a look at this post over at Ubuntu forums for a very comprehensive, yet easy to understand guide to Grub2.  Noteworthy mentions are as follows:

“At first boot, there will not be much difference in what the user sees on the boot menu. The one exception is a clean install of Ubuntu 9.10 with no other installed operating system. In this case, GRUB 2 will boot directly to the login prompt or Desktop without displaying a menu. Other major differences:

  • No ”/boot/grub/menu.lst”. It has been replaced by ”/boot/grub/grub.cfg”.
  • Hold down SHIFT to display the hidden menu during boot (formerly ESC is GRUB legacy).
  • There is no “find /boot/grub/stage1″ at the grub prompt. Stage 1.5 has also been eliminated.
  • The main menu file, ”/boot/grub/grub.cfg” is not meant to be edited, even by ‘root’.
  • ”grub.cfg” is overwritten anytime there is a update, a kernel is added/removed or the user runs `update-grub` *
  • The user can use a custom file, ”/etc/grub.d/40_custom”, in which the user can place his own entries. This file will ”not” be overwritten.
  • The primary configuration file for changing menu display settings is ”/etc/default/grub”.
  • There are multiple files for configuring the the menu – ”/etc/default/grub” mentioned above, and all the files in ”/etc/grub.d/” folder.
  • Other operating systems, such as Windows, should automatically be recognized and added to the menu.
  • No changes made in the configuration files will take effect until the `update-grub` command is also run.”

Big thanks to our author : http://ubuntuforums.org/member.php?u=223945

Original Post : http://ubuntuforums.org/showthread.php?t=1195275

Read More

Ubuntu Karmic 9.10 and Gigabyte GA-EP45-UD3P – Black screen

After any install of Karmic, 9.10 the new GRUB 2 bootloader will not start the generic kernel. On first reboot after a fresh install, when you select the standard boot image you are left with a black screen, and possibly a blinking cursor in the upper left hand corner.  To boot anything functional I was forced to start in rescue mode, resume normal boot, login as my user, then run startx to start GNOME. What a disaster! Simple fix? You got it!

It’s time to edit Grub2, a daunty little beast that is not to be mistaken for Grub.

1. Open the grub config

1
sudo gedit /etc/default/grub

2. A note : grub.cfg cannot be modified without changing the file permissions first. Do not modify /boot/grub/grub.cfg Simply put, every time you run update-grub this file is re-generated. Changes here can be dangerous.

3. Find the following, or similar depending on your kernel

1
linux   /boot/vmlinuz-2.6.31-14-generic root=UUID=94db3b6d-1959-49d3-8565-6e3e28acdc64 ro   quiet splash

4. Remove “quiet splash”

1
linux   /boot/vmlinuz-2.6.31-14-generic root=UUID=94db3b6d-1959-49d3-8565-6e3e28acdc64 ro

5. Run

1
sudo update-grub

6. Reboot

Read More

Cannot connect to MySQL: Client does not support authentication protocol requested by server

I ran into a problem on a client site running cPanel. One our our web apps was spitting out the following error:

1
2
Script Error
Cannot connect to MySQL: Client does not support authentication protocol requested by server; consider upgrading MySQL client

A quick Google search returned the fix : http://geekswithblogs.net/TimH/archive/2005/10/31/58591.aspx

From inside MYSQL, Run the following on the affected DB:

1
SET PASSWORD FOR user@localhost = OLD_PASSWORD('replacemepasswd');
Read More

The Perfect Bag – Consulting

Supporting multiple operating systems on all types of different hardware configurations seems to be a daunting task, however in my daily routine I find that a perfect balance in the bag can really make this job a lot easier.

What’s in the bag!

-320GB External USB Hard Drive – 7200 RPM/SATA/USB
(2 screws to open external exclosure)

-Macbook (2.1Ghz C2D, 3GB Ram, 320 GB 7200 RPM HD)
Parallels running Windows 7 and Ubuntu 9.04

-Headphones

-Small Screwdriver Set

-USB Charger – large/mini usb for Blackberry

-iPhone w Charger
Jailbroken w/SSH

-Dual USB charger, with miniUSB

-Sprint Unlocked Blackberry 9630 Tour

-8GB USB Key

-3FT Firewire Cable

What do I need?
Well, I would one day like to be able to replace the Macbook with a well partitioned netbook.

Read More

Maison des Tilleuls : Le Blanc-Mesnil, France

Problem:
15 donated and poorly configured machines needed to be cleaned up and ready for local community volunteers who teach basic computer skills to members of the Paris suburb Le Blanc-Mesnil (map)

Maison des Tilleuls

http://www.maisondestilleuls.org/

Configuration:
The mix of hardware included a Core II Duo, Pentium 4′s, Pentium III’s, and with an upper limit of 1gb of memory, and a lower limit of 256mb. The more powerful machine’s had Vista installation’s that were quite literally sucking the life force out of the air. (Booting in 5 minutes, taking over 3 minutes to launch Internet Explorer, and running Norton Anti-Virus). In my mind, and the hands of the user – completely unusable and not conducive to a learning/teaching environment. My first question to the director was : Can I completely take control of this situation and ideally configure each machine to a Linux based operating environment? Once I had gotten the key’s to the castle, here is what I did.

All had working CD-Rom drives and few had the ability to boot from a USB stick.

The Pentium III machines were configured and running happily with Fedora 5.

The operating system of choice was Ubuntu 9.04 Jaunty, while this was the preference with an EXT4 filesystem and the most driver support to boot. There was a lot(10) of Dell Optiplex GX240′s which would not boot Ubuntu 9.04. Upon default installation, on intial reboot GRUB only returned BOOT with a flashing cursor. Ubuntu 8.04 had no problems installing and booting on these machines, but without the added benefit’s and speed of the EXT4 file system.

Solutions:

In this mix of hardware, not all the ethernet drops(wired to the walls) were working. One of the first tasks was to test each drop and label the plastic casing with an O for working/open and an X for not working/closed.

While one machine would install, I used the faster machines to burn extra install CD’s as one does not usually need nor carry much more than one. Other minor configuration tasks included setting up a Linksys Wireless router as a Public AP and a Wireless Laser Printer. Ubuntu 9.04 carried the drivers for the networked printer, while 8.04 needed the PPD file Brother so tastefully provided for Linux.

I setup the ideal environment for a basic user sitting down to a desktop for their first time. The menu bar was positioned on the bottom, 40px in height. A generic blue background color was determined. Editing the menu’s was an easy way to pare down the daunting set of options Ubuntu has enabled by default, and setup of Users/Groups involved invoking a root password, and configuring the “Administration” capabilities of the default user. To note here, once “Users and Groups” was configured and I had disabled most/all administration tasks for the default user, even unlocking this control panel via the root password was impossible once inside of X, and would require you to sudo -s in the terminal to make any real changes. At the end of the day, without a root password and serious knowledge of the terminal the user was presented with a desktop that looked as follows:

configured 9.04 desktop

configured 9.04 desktop

Maison des Tilleuls
7 Square Maurice Audin – 93150 Le Blanc Mesnil
Tél : 01.45.91.97.00 – Fax : 01.45.91.97.09

www.maisondestilleuls.org

Du lundi au vendredi, de 8h à 12h30
et de 13h30 à 20h. Le samedi de 9h à 18h.

Moving forward:
Once all the Ethernet drops are operating I will assign static IP address’s to each of the machines. Installing SSH via

1
sudo apt-get install ssh

Will allow me to remotely login, upgrade, and maintain these systems at distance. Create a more user friendly desktop and continuing to pare down the user permissions to obtain an optimal balance of usability/functionality and security/performance. My intention is to create the most user friendly and appealing desktop environment for a user who sitting down to a computer for the first time, albeit an Ubuntu PC.

Read More