Solved

How to mount a FreeBSD drive to a folder on a OpenSuse Linux Box

Posted on 2007-11-14
17
1,503 Views
Last Modified: 2013-12-16
I have a FreeBSD drive that I want to get its data. I have piggybacked it as a slave to my OpenSuSE box I can see it as /dev/sdb. The partition I want is /dev/sdb1. I am trying to mount it to /home/eric/data.

I have run a series of mount commands with different switches, but obviously, I am missing something. This was one of them:

mount -t ufs /dev/sdb1 /home/eric/data

This was its output:

mount: wrong fs type, bad option, bad superblock on /dev/sdb1,
       missing codepage or helper program, or other error
       In some cases useful info is found in syslog - try
       dmesg | tail  or so


HELP!
0
Comment
Question by:emherman
  • 5
  • 5
  • 2
  • +3
17 Comments
 
LVL 12

Expert Comment

by:ibu1
ID: 20287079
) Install hard disk to your computer
2) boot your computer
3) dmesg | less
                                         From the output, look for an indication that the new hard disk was found. For example, if it is a secound IDE, you should see "hdb" in the output.Be sure you idenify the right disk.I mean to say u should find hdb1 or hdb2,etc
from the dmesg| less output.
Make one directory where u want to mount the partition
example /home/eric/data
14) Edit the fstab file
/dev/sdb1               /home/eric/data             ext3         defaults         1 1
0
 
LVL 87

Expert Comment

by:rindi
ID: 20287708
You could also try ext2 or auto. It depends on the filesystem the partition was formatted with. As far as I know freebsd uses ext2 and ext3 by default. If you don't have luck this way, try booting with a LiveCD like knoppix, it tries to guess the filesystems used, and then you could mount the drives there and directly copy the data you need, or you could look at what fstab shows you and then use those settings when you boot to opensuse again.

http://knoppix.net
0
 
LVL 29

Expert Comment

by:TeRReF
ID: 20288085
I mount it like this in fstab:

/dev/sdb1  /home/eric/data  ufs  auto,rw,ufstype=ufs2, nodev,nosuid  0  0
0
 
LVL 87

Expert Comment

by:rindi
ID: 20288821
Then you probably don't have the ufs filesystem module on your system, as that isn't used very commonly. You'd either have to download the kernel sources and include the ufs module, or try knoppix which may have that module included.
0
 
LVL 1

Author Comment

by:emherman
ID: 20291611
I did a /cat/proc/filesystems and "ufs" was listed (and ext3). It was missing the "nodev" entry if that makes a diff.

BTW - I don't need to permanently mount the drive. I just need to get temporary access to it to pull off data and get it on the Linux box. Will I need to set up the fstab entries or can I get away with juts using the mount command?

If I load Knoppix will I still have access to the hard drive to put the data or will it run entirely off the CD?
0
 
LVL 1

Author Comment

by:emherman
ID: 20291752
... did not see ufs2 listed
0
 
LVL 87

Expert Comment

by:rindi
ID: 20291758
With knoppix you should have access to all disks that the OS sees. It loads KDE and the disks normally are shown on the desktop. Click on it and it opens. If you then right click that icon again, you should have an option to change the read/write mode of the partition (knoppix loads everything in read only mode by default). You can also mount network folders and copy the data to those if you want.
0
 
LVL 1

Author Comment

by:emherman
ID: 20291774
... btw - I would just need read-only access, since I do not plan to use the drive after I get the data off.
0
What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

 
LVL 1

Author Comment

by:emherman
ID: 20291793
The drive was running FreeBSD 4.11
0
 
LVL 87

Expert Comment

by:rindi
ID: 20291846
You will need writing access to the disk you want to copy the data to.
0
 
LVL 1

Author Comment

by:emherman
ID: 20293970
OK. I tried Knoppix, and got to the desktop. I see "hdb1" on the desktop and clicked on it. I get:

------------------------------------------

Could not mount the device.

The reported error was:

mount: I could not determine the filesystem type, and none was specified

-----------------------

What now?
0
 
LVL 87

Accepted Solution

by:
rindi earned 84 total points
ID: 20296693
Try installing a small freebsd pc with just the essentials, and then try mounting the Disk there.
0
 
LVL 29

Expert Comment

by:TeRReF
ID: 20297272
Was the drive dismounted properly? Are there any errors that might prevent proper mounting of the drive?
0
 
LVL 61

Assisted Solution

by:gheist
gheist earned 84 total points
ID: 20300690
Boot off latest FreeBSD CD Get into recovery mode
chroot /dist
mount_devfs /dev
fsck /dev/ad0s1[a-i]
0
 
LVL 17

Assisted Solution

by:CSecurity
CSecurity earned 84 total points
ID: 20311212
I had a similar problem trying to mount by FreeBSD partition from OpenSUSE

add "-r -t ufs -o ufstype=44bsd" to your mount command like this:

mount -r -t ufs -o ufstype=44bsd /dev/sdb1 /home/eric/data
0
 
LVL 61

Expert Comment

by:gheist
ID: 20311235
One should fsck from FreeBSD anyway.  UFS2 not supported in Linux kernel.
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

More or less everybody in the IT market understands the basics of Networking, however when we start talking about Storage Networks, things get a bit dizzier, and this is where I would like to help.
Ever notice how you can't use a new drive in Windows without having Windows assigning a Disk Signature?  Ever have a signature collision problem (especially with Virtual Machines?)  This article is intended to help you understand what's going on and…
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now