Tag Archives: ubuntu

This post will tell you how to repair / fix Mac HFS+ partition using Ubuntu CD (Live CD or Install CD).

What do you need to do this?
Ubuntu CD (I used Ubuntu 8.10 Desktop Edition Install/Live CD)
Mac
Internet Connection (Wired)

Few days back I had installed Debian 5.0 lenny on my MacBook. Because, I don’t have much hard disk capacity (only 80 GB), I had to delete the Linux partition (waiting for Ubuntu 9.04).  I used BootCamp Utility (in Mac) to delete the Linux partition. It wipes off all the linux data & restores Mac partition (ex: I had 60GB Mac + 20GB Linux, After restore 80GB* Mac).
I was happy that it was restored. But, the partition had errors after restores. I was not able to copy/store the any data if it exceeds 60GB on Mac, it says the Mac startup disk is full. Then I realized that the Mac file system (i.e., HFS+) had errors. Yes, the Ubuntu CD is there to rescue me. Enough story… follow this to proceed…

1. Disable journaling on Mac parition before booting into Ubuntu CD
Use this command on your Mac terminal

  • sudo diskutil disableJournal /dev/disk0s2

where disk0s2 is your Mac partition (use ‘df’ command to find out the root disk name, it should be mounted on ‘/’)

2. Boot from Ubuntu CD
Insert the Ubuntu CD, press ‘C’ on startup to boot from CD.

3. Connect to Internet & Install HFSprogs
After Boot connect to Internet, Yeah! I know the wireless won’t work now. I suggest you to connect from Wired.
I assume that you are connected to Internet now.
Then enable Universe packages using ‘Software Sources’.
Then, Install hfsprogs package

  • sudo apt-get install hfsprogs

    This will enable you to check & repair the HFS+ paritions.

    4. Check & Repair

    You need to do fsck check on your Mac partition. Use fdisk command to find the Mac device.

    abhinay@ubuntu:~$ fdisk -l
    WARNING: GPT (GUID Partition Table) detected on ‘/dev/sda’! The util fdisk doesn’t support GPT. Use GNU Parted.

    Disk /dev/sda: 80.0 GB, 80026361856 bytes
    255 heads, 63 sectors/track, 9729 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
    Disk identifier: 0×00000000
    Device Boot Start End Blocks Id System
    /dev/sda1 1 9730 78150743+ ee GPT

    using fdisk didn’t show the Main Partition of mac, It shows only one partition. The above partition sda1 is the EFI partition (boot partition).
    That means, /dev/sda2 is your Mac partition.

    Perform fsck on sda2

    abhinay@ubuntu:~$ sudo fsck.hfsplus /dev/sda2
    ** /dev/sda2
    ** Checking HFS Plus volume.
    ** Checking Extents Overflow file.
    ** Checking Catalog file.
    ** Checking multi-linked files.
    ** Checking Catalog hierarchy.
    ** Checking Extended Attributes file.
    ** Checking volume bitmap.
    Volume Bit Map needs minor repair
    ** Checking volume information.
    ** Repairing volume.
    ** Rechecking volume.
    ** Checking HFS Plus volume.
    ** Checking Extents Overflow file.
    ** Checking Catalog file.
    ** Checking multi-linked files.
    ** Checking Catalog hierarchy.
    ** Checking Extended Attributes file.
    ** Checking volume bitmap.
    ** Checking volume information.
    ** The volume Macintosh HD was repaired successfully.

    Hurray! It is repaired now…!

    One more last thing you ‘ll have to do.

    5. Enable the journaling on Mac Partition
    use this command on Mac to enable the journal back.

    sudo diskutil enableJournal /dev/disk0s2

    You are done! :)

    **This worked for me!

    Comment me if you have any troubles or suggestions. Thanks for reading my blog!

    Openbox is lightweight window manager. I installed it on my gentoo, i really liked it. Openbox starts in blink of an eye my gentoo.Openbox just takes seconds to install in any distro. It comes around 500 Kb download size. I have been using GNOME environment in Ubuntu. I feel like GNOME is too slow in my system. I installed openbox and used with gnome session. It is really faster than complete GNOME session. You can change the session from the GDM option menu. Select, Openbox with GNOME session. You’ll get gnome panel, nautilus and other gnome apps with faster openbox window manager without losing the most of the gnome look & features. Openbox rocks !!!

    I did,
    sudo aptitude install openbox

    and here is the screenshot for you ;)

    Openbox in Gnome Screenshot - Openbox Rox

    Openbox in Gnome Screenshot - Openbox Rox | Running Urxvt, Scrot, Gnome-panel, Conky, Nautilus, Xcompmgr and some applets

    Hey folks, i have a good news for music lovers. I have just got a workaround to play songs from Raaga.com in Linux.

    I tried with Ubuntu Hardy Heron 8.04 & Firefox 3.0 b 5. I followed this article http://www.zyxware.com/articles/2008/04/27/setting-up-raaga-com-to-work-on-ubuntu-8-04-hardy-heron . Credit goes to that article.

    I guess, /usr/lib/totem/gstreamer/libtotem-complex-plugin.so plugin caused a problem for raaga player. After removing this plugin, it was working.

    This plugin, (remove this plug-in)

    Helix DNA Plugin: RealPlayer G2 Plug-In Compatible (compatible; Totem)
    
        File name: libtotem-complex-plugin.so
        The Totem 2.22.1 plugin handles video and audio streams.
    
    MIME Type 	Description 	Suffixes 	Enabled
    audio/x-pn-realaudio-plugin 	RealAudio document 	rpm 	Yes

    Here is how,

    Download the latest Realplayer from here http://forms.helixcommunity.org/helix/builds/?category=realplay-current And save it to desktop,

    Select Platform: linux-2.2-libc6-gcc32-i586 > RealPlayer (bin)

    (Or you can also download from here – http://www.real.com/linux)

    [ I suggest you to uninstall realplayer from your Linux if it is already installed, sudo apt-get purge realplayer ]

    Install the RealPlayer,

    • cd Desktop/
    • chmod +x realplay-10.1.0.4350-linux-2.2-libc6-gcc32-i586.bin

    Here, change the realplay-10.1.0.4350-linux-2.2-libc6-gcc32-i586.bin with the filename that you have downloaded.

    • sudo ./realplay-10.1.0.4350-linux-2.2-libc6-gcc32-i586.bin

    Set Plugins,

    • cd /usr/lib/firefox-addons/plugins
    • sudo ln -s /opt/real/RealPlayer/mozilla/nphelix.xpt nphelix.xpt
    • sudo ln -s /opt/real/RealPlayer/mozilla/nphelix.so nphelix.so
    • sudo rm /usr/lib/totem/gstreamer/libtotem-complex-plugin.so

    Restart Firefox,

    Now enjoy the music. :)

    http://raaga.com/channels/telugu/top10.asp

    If you still have any problems please let me know, i ‘ll try to help you out.

    Playing Raaga.com,

    raaga ubuntu linux

    This is my about:plugins page on Firefox.

    Installed plugins
    Find more information about browser plugins at mozilla.org.
    Help for installing plugins is available from plugindoc.mozdev.org.
    Helix DNA Plugin: RealPlayer G2 Plug-In Compatible
    
        File name: nphelix.so
        Helix DNA Plugin: RealPlayer G2 Plug-In Compatible version 0.4.0.4005 built with gcc 3.4.3 on Feb 25 2008
    
    MIME Type     Description     Suffixes     Enabled
    audio/x-pn-realaudio-plugin     RealPlayer Plugin Metafile     rpm     Yes
    Shockwave Flash
    
        File name: libflashplayer.so
        Shockwave Flash 9.0 r124
    
    MIME Type     Description     Suffixes     Enabled
    application/x-shockwave-flash     Shockwave Flash     swf     Yes
    application/futuresplash     FutureSplash Player     spl     Yes
    Default Plugin
    
        File name: libnullplugin.so
        The default plugin handles plugin data for mimetypes and extensions that are not specified and facilitates downloading of new plugins.
    
    MIME Type     Description     Suffixes     Enabled
    *     All types     .*     No
    Demo Print Plugin for unix/linux
    
        File name: libunixprintplugin.so
        The demo print plugin for unix.
    
    MIME Type     Description     Suffixes     Enabled
    application/x-print-unix-nsplugin     Demo Print Plugin for Unix/Linux     .pnt     Yes
    iTunes Application Detector
    
        File name: librhythmbox-itms-detection-plugin.so
        This plug-in detects the presence of iTunes when opening iTunes Store URLs in a web page with Firefox.
    
    MIME Type     Description     Suffixes     Enabled
    application/itunes-plugin             Yes
    Totem Web Browser Plugin 2.22.1
    
        File name: libtotem-basic-plugin.so
        The Totem 2.22.1 plugin handles video and audio streams.
    
    MIME Type     Description     Suffixes     Enabled
    application/x-ogg     -     ogg     Yes
    application/ogg     Ogg multimedia     ogg     Yes
    audio/ogg     Ogg Audio     oga     Yes
    audio/x-ogg     Ogg Audio     ogg     Yes
    video/ogg     Ogg Video     ogv     Yes
    video/x-ogg     Ogg Video     ogg     Yes
    application/annodex     -     anx     Yes
    audio/annodex     -     axa     Yes
    video/annodex     -     axv     Yes
    video/mpeg     MPEG video     mpg, mpeg, mpe     Yes
    audio/wav     WAV audio     wav     Yes
    audio/x-wav     WAV audio     wav     Yes
    audio/mpeg     MP3 audio     mp3     Yes
    application/x-nsv-vp3-mp3     NullSoft video     nsv     Yes
    video/flv     Flash video     flv     Yes
    VLC Multimedia Plugin (compatible Totem 2.22.1)
    
        File name: libtotem-cone-plugin.so
        The Totem 2.22.1 plugin handles video and audio streams.
    
    MIME Type     Description     Suffixes     Enabled
    application/x-vlc-plugin     unknown         Yes
    application/vlc     unknown         Yes
    video/x-google-vlc-plugin     unknown         Yes
    Windows Media Player Plug-in 10 (compatible; Totem)
    
        File name: libtotem-gmp-plugin.so
        The Totem 2.22.1 plugin handles video and audio streams.
    
    MIME Type     Description     Suffixes     Enabled
    application/x-mplayer2     AVI video     avi, wma, wmv     Yes
    video/x-ms-asf-plugin     ASF video     asf, wmv     Yes
    video/x-msvideo     AVI video     asf, wmv     Yes
    video/x-ms-asf     ASF video     asf     Yes
    video/x-ms-wmv     Windows Media video     wmv     Yes
    video/x-wmv     Windows Media video     wmv     Yes
    video/x-ms-wvx     Microsoft ASX playlist     wmv     Yes
    video/x-ms-wm     ASF video     wmv     Yes
    application/x-ms-wms     Windows Media video     wms     Yes
    application/asx     Microsoft ASX playlist     asx     Yes
    audio/x-ms-wma     Windows Media audio     wma     Yes
    DivX® Web Player
    
        File name: libtotem-mully-plugin.so
        DivX Web Player version 1.4.0.233
    
    MIME Type     Description     Suffixes     Enabled
    video/divx     AVI video     divx     Yes
    QuickTime Plug-in 7.2.0
    
        File name: libtotem-narrowspace-plugin.so
        The Totem 2.22.1 plugin handles video and audio streams.
    
    MIME Type     Description     Suffixes     Enabled
    video/quicktime     QuickTime video     mov     Yes
    video/mp4     MPEG-4 video     mp4     Yes
    image/x-macpaint     MacPaint Bitmap image     pntg     Yes
    image/x-quicktime     QuickTime image     pict, pict1, pict2     Yes
    video/x-m4v     MPEG-4 video     m4v     Yes
    GCJ Web Browser Plugin (using IcedTea) 1.0
    
        File name: gcjwebplugin.so
        The GCJ Web Browser Plugin (using IcedTea) executes Java applets.
    
    MIME Type     Description     Suffixes     Enabled
    application/x-java-vm     IcedTea     class,jar     Yes
    application/x-java-applet     IcedTea     class,jar     Yes
    application/x-java-applet;version=1.1     IcedTea     class,jar     Yes
    application/x-java-applet;version=1.1.1     IcedTea     class,jar     Yes
    application/x-java-applet;version=1.1.2     IcedTea     class,jar     Yes
    application/x-java-applet;version=1.1.3     IcedTea     class,jar     Yes
    application/x-java-applet;version=1.2     IcedTea     class,jar     Yes
    application/x-java-applet;version=1.2.1     IcedTea     class,jar     Yes
    application/x-java-applet;version=1.2.2     IcedTea     class,jar     Yes
    application/x-java-applet;version=1.3     IcedTea     class,jar     Yes
    application/x-java-applet;version=1.3.1     IcedTea     class,jar     Yes
    application/x-java-applet;version=1.4     IcedTea     class,jar     Yes
    application/x-java-applet;version=1.4.1     IcedTea     class,jar     Yes
    application/x-java-applet;version=1.4.2     IcedTea     class,jar     Yes
    application/x-java-applet;version=1.5     IcedTea     class,jar     Yes
    application/x-java-applet;version=1.6     IcedTea     class,jar     Yes
    application/x-java-applet;jpi-version=1.6.0_00     IcedTea     class,jar     Yes
    application/x-java-bean     IcedTea     class,jar     Yes
    application/x-java-bean;version=1.1     IcedTea     class,jar     Yes
    application/x-java-bean;version=1.1.1     IcedTea     class,jar     Yes
    application/x-java-bean;version=1.1.2     IcedTea     class,jar     Yes
    application/x-java-bean;version=1.1.3     IcedTea     class,jar     Yes
    application/x-java-bean;version=1.2     IcedTea     class,jar     Yes
    application/x-java-bean;version=1.2.1     IcedTea     class,jar     Yes
    application/x-java-bean;version=1.2.2     IcedTea     class,jar     Yes
    application/x-java-bean;version=1.3     IcedTea     class,jar     Yes
    application/x-java-bean;version=1.3.1     IcedTea     class,jar     Yes
    application/x-java-bean;version=1.4     IcedTea     class,jar     Yes
    application/x-java-bean;version=1.4.1     IcedTea     class,jar     Yes
    application/x-java-bean;version=1.4.2     IcedTea     class,jar     Yes
    application/x-java-bean;version=1.5     IcedTea     class,jar     Yes
    application/x-java-bean;version=1.6     IcedTea     class,jar     Yes
    application/x-java-bean;jpi-version=1.6.0_00     IcedTea     class,jar     Yes
    Helix DNA Plugin: RealPlayer G2 Plug-In Compatible
    
        File name: nphelix.so
        Helix DNA Plugin: RealPlayer G2 Plug-In Compatible version 0.4.0.633 built with gcc 4.2.3 on Apr 1 2008
    
    MIME Type     Description     Suffixes     Enabled
    audio/x-pn-realaudio-plugin     RealPlayer Plugin Metafile     rpm     Yes