?
Solved

Unix/Windows Sharing and Mounting partitions

Posted on 2003-03-02
9
Medium Priority
?
175 Views
Last Modified: 2013-12-27
I've installed Samba, and had relatively no problems connecting to a shared directory on Solaris.  Now I'd like to go the other way.  Ultimately, what I want to accomplish is this: (however, if I just receive info on sharing a windows directory from my Solaris, that'd be good too)

prompt# ufsdump 0cfu /dev/rmt/2 /dev/rdsk/c0t3d0s0
   ...OR, something like this...
prompt# ufsdump xfs /dev/rmt/2

Where /dev/rmt/2 (which doesn't exist yet) is a shared "virtual mount point" located on a Windows Box.  I know I'll loose permissions...because of the Windows NTFS, but I'd like to simple restore the data to this drive.

Thanks for any comments.  With any proposed solutions, please let me know of any security holes that may exist...or to watch out for.

0
Comment
Question by:ramble
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 3
9 Comments
 
LVL 38

Expert Comment

by:yuzh
ID: 8055387
I hope that I can understand your question, do you want to mirroring/synchronized the 2 filesystems (dirs). if it is the case, use "rsync" to do the job,

you can download "rsync" from" (FREE)

http://sunfreeware.com/

The systax for using rsyns:
 /usr/local/bin/rsync --delete -az /dir1 /dir2

man rsync

to learn more details



0
 
LVL 8

Expert Comment

by:heskyttberg
ID: 8056718
Hi!

I don't think this can be done in Solaris.

A workaround that would work for you would be the following.

With samba on Solaris box, share a dir you call backup or restore or something other intelligent.

Do an ufsdump to that dir. I necessary add a disk to Solaris machine to just store this backup.

Install svcrsh service on windoes box, it's in resource kit for both NT and w2k.

When the ufsdump finishes run a script through rsh on wndows box that copies the ufsdump file from the backup share.

In script on windows box either map tha share or jsut do copy \\solarisbox\backup\daily_dump.dmp d:\backup.sol

Or something.

I don't understand why you do it like this though.
If you use veritas to take backup, just donload veritas solaris remote agent and install it.

This is how we are doing it. Then just wait for a while go to windows box doing backup and you should have a new choices in selection where you will find you solaris machine.

Regards
/Hans - Erik Skyttberg
0
 

Author Comment

by:ramble
ID: 8058048

yuzh:  To help clarify what I want:  I can get to my Solaris box from windows quite easily.  I simply go to "my network places" and browse to the unix computer name...and copy or save files to the directory I am sharing from my Unix box.

Now...I'd like to do the same thing...in reverse.  I'd like to somehow "mount" a directory that is shared from the Windows box, so I can copy files and directories from Unix to windows.

heskyttberg:  I can't do what you suggest.  My Solaris Box has over 70Gigs of info, and only about 10 Gigs free.  So I can't do a ufsdump to a directory, because there isn't near enough room.

Is veritas a commercial product?  If so, budget times are tough...so this would't be an option at this time.

-=-=-=-=-=-=-
Please don't overlook the obvious!  :^)  There may be a simple way to browse, and use a windows directory that I'm simply not aware of.

How would this change if I set-up a Linux box (in place of the windows box).  How would you share directories from Unix to Linux across the network?

Thanks again, for you input.


0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 8

Expert Comment

by:heskyttberg
ID: 8060979
Hi!

It would change quite a bit if you use a linux box.

Since both linux and solaris can use NFS.

So you could just NFS share dir on linux box and mount it on solaris box.

In linux in order to get onto a windows share you can do this:

I usually do like this.
Create a dir under /mnt called winsrvname_share or something so I know what it is if I plan to use many.
If I only plan to use one I just create a dir under /mnt called smbfs.

Then I can do this:
mount -t smbfs -o username=windowsusername -o password=winpasswd //winservername/share /mnt/smbfs

You can ommit -p password, then you'll be prompted for one.

Now you can just copy files from anywhere on the linux box to /mnt/smbfs

Regards
/Hans - Erik Skyttberg
0
 

Author Comment

by:ramble
ID: 8061268
heskyttberg:

Ok.  That sounds easy enough.  I created the directory under /mnt/mydir on my Solaris and mounted it from the linux box.  I can see the contents...but root owns part if it, and USER owns part of it.  If I'm root...I can go view the contents that root owns, but not the contents that USER owns.  If I'm user...I can view the contents that USER owns...but not root (which is how it should be).

How come root can't view USER using the mnt?

What kind of security holes are in using this method?  And...is it possible to mount the tape drive of the Solaris box from the linux box...and have linux us the tape drive?

0
 
LVL 8

Accepted Solution

by:
heskyttberg earned 600 total points
ID: 8062896
Hi!

I'm not sure about that, I'm not an NFS expert, but I never had any such problems when mounting with NFS.

Maybe you need to add a parameter in the /etc/exports on Linux box: no_root_squash
So /exported/dir exportname(rw, no_root_squash)

Before you do read this though:
http://nfs.sourceforge.net/nfs-howto/security.html

If on internal LAN behind firewall, you might not be too concerned with security, but more with ease of use.

As long as you don't nfs export '/' dir on either Solaris or Linux and perhpas also limit which IP is allowed to mount the nfs shares there really isn't much o security hole.

I don't think you can mount the tape from solaris on linux.
I'm not very good at all with tape devices in solaris.

But if it would be possible to mount the tape device in a dir on Solaris box which you then export with NFS and mount in Linux. Then maybe you can copy stuff from linux box onto the tapedevice.

Regards
/Hans - Erik Skyttberg
0
 

Author Comment

by:ramble
ID: 8064829
heskyttberg:

You've been great.  You've given me a lot of things to consider, and think about.  I'll probably create a more "pointed" question, and see if I can pull in an NFS expert.

-Thanks
0
 

Author Comment

by:ramble
ID: 10893457
Thanks_ramble

Just Ignore the last comment
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Let's say you need to move the data of a file system from one partition to another. This generally involves dismounting the file system, backing it up to tapes, and restoring it to a new partition. You may also copy the file system from one place to…
Why Shell Scripting? Shell scripting is a powerful method of accessing UNIX systems and it is very flexible. Shell scripts are required when we want to execute a sequence of commands in Unix flavored operating systems. “Shell” is the command line i…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
Suggested Courses
Course of the Month13 days, 4 hours left to enroll

777 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