Monday, March 21, 2011

Flexnet Sector 32

More notes to self.

Was just trying to reinstall grub on a disk on which I had accidentally trashed the partition table (It's the WRONG DISK Grommet !)

I noticed the following error when I ran grub-install :

/usr/sbin/grub-setup: warn: Sector 32 is already in use by FlexNet; avoiding it.  This software may cause boot or other problems in future.  Please ask its authors not to store data in the boot track..

I thought I would see what gives. Seems that this is related to Adobe DRM stuff. What I want to know is why this sort of thing is left lying around long after Windows/Adobe has gone. Despite formatting and partitioning, someone else's crap is still on MY disk. Unacceptable.

There are two ways to get shot.

1. A low level format / disk wipe - but I couldn't believe there wasn't another way.

2. Zero out the MBR and reinstall grub. Much better and as follows :


http://ubuntuforums.org/showthread.php?t=1661254

BACKUP FIRST :
sudo dd if=/dev/sda of=~/first_63_sectors bs=512 count=63


To zero all sectors do this (take a backup first !) :
sudo dd if=/dev/zero of=/dev/sda bs=512 count=62 seek=1

Or just the sector 32 :
sudo dd if=/dev/zero of=/dev/sda bs=512 count=1 seek=32

Seems that there are several other programs that perform similar tricks.

To chroot and reinstall grub

sudo mount /dev/sda1 /media/sda1

sudo mount --bind /dev /media/sda1/dev
sudo mount --bind /proc /media/sda1/proc
sudo mount --bind /sys /media/sda1/sys
sudo chroot /media/sda1

sudo update-grub

Job done. Roll a smoke and get a coffee.

9 comments:

  1. Thanks, I had the same problem, now it's solved thanks again :)

    ReplyDelete
  2. I had this "chroot: failed to run command `/bin/bash': No such file or directory" when I run "sudo chroot /mnt".

    Help me please!

    ReplyDelete
  3. Assuming you have mounted the correct disk/partitions/directories then I guess the answer is that there must be something wrong with your installation somehow.

    Can you boot with a live distro & have a look to see that everything is in place ?

    ReplyDelete
  4. Thanks a lot for this. I have been looking for how to rid off flexnet without wipe out disk almoust half a day (especially not to use low level formatting - quite danger operation).
    if please anybody has further information how to check MBR/63 sectors if it is clean - I mean if it is without any other DRM or similar stupid stuff, please post it here. I would really much appreciate it.

    Kind Regards,
    Martin

    ReplyDelete
  5. Appreciate the instruction. I am a huge fan of dd now :)

    ReplyDelete
  6. Sorry for the late response - trying to figure out to comment on your own post !!

    Martin, just check the backup file and compare it with a newer version after zeroing the drive. Should find a new dd backup should show a pile of noughts ! If it is, no need to look further !

    Lucid, thanks. Me too - neat tool that is often forgotten or overlooked.

    B. Rgds
    John

    ReplyDelete
  7. Where's the "grub-install /dev/sda" ? I don't see that in your list of commands. Shouldn't that be done just before update-grub? It seems like your MBR would still be a bunch of nulls after the above commands. Yet feedback comments don't mention any problems. What am I missing?

    ReplyDelete
  8. Hi,

    first, note that there are TWO dd instructions - one to zero all bytes and the other JUST Sector 32. If you run the Sector 32 only one then you won't end up with a bunch of nulls......

    Regards update-grub I can't honestly say as I am no expert in that field. Think it all depends on what is already installed in the boot sector/partition table.

    I just did the above and it worked :-)

    ReplyDelete
  9. sudo update-grub
    should be replaced with
    sudo grub-install /dev/sdX

    "X" should be the correct one, such as "a".

    ReplyDelete