• Recent
  • Unsolved
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Register
  • Login
  • Recent
  • Unsolved
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Register
  • Login

Use Windows share to store fog image with cifs on Ubuntu

Scheduled Pinned Locked Moved
Tutorials
2
2
1.7k
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M
    mutant
    last edited by mutant Apr 20, 2017, 7:43 AM Apr 20, 2017, 1:33 PM

    Reason:

    For the people that do not want to setup NFS server on windows but want to use windows share to store fog images.

    Windows share that use CIFS/SMB mount will only work with user space NFS server such as unfsd3 or NFS-Ganesha

    The regular kernel mode nfs_kernel_server does not compiled to support NFS re-export.

    Assume you have a windows server with a share folder call fogshare and the share user is fog with the password fog. The FOG sever is on Ubuntu server.

    sudo -i
    #install CIFS support
    apt-get install cifs-utils

    #Backup images folder so you can copy .mntcheck file later
    mv /images /images.old
    mkdir images
    chmod -R 777

    #edit /etc/fstab to add the following line so windows share folder will mount to /images
    //windows server IP or name/fogshare /images cifs username=fog, password=fog,noserverinfo,iocharset=utf8,file_mode=0777,dir_mode=0777,sec=ntlmssp 0 0

    #backup /etc/exports
    cp exports exports_nfs_kernal_server

    #remove nfs_kernal_server
    apt-get remove nfs-kernal-server

    #add the unfsd3 server source to /etc/apt/sources.list
    #add archive lucid apt source for unfsd3
    #Lucid
    deb http://old-releases.ubuntu.com/ubuntu/ lucid main restricted universe
    deb-src http://old-releases.ubuntu.com/ubuntu/ lucid main restricted universe

    #install unfs3
    apt-get update
    apt-get install unfs3

    #unfs3 does not like a * in the /etc/exports
    replace the * with internal network x.x.x.x/24

    /images x.x.x.x/24(ro,sync,no_wdelay,no_subtree_check,insecure_locks,no_root_squash,insecure,fsid=0)
    /images/dev x.x.x.x/24(rw,async,no_wdelay,no_subtree_check,no_root_squash,insecure,fsid=1)

    #backup exports for future use
    cp /etc/exports /etc/exports_ufs3

    #copy /image.old files to the new /images

    #restart unfs3
    /etc/init.d/unfs3 restart

    This works on Ubuntu 14.04 and should work with other version as well.

    1 Reply Last reply Reply Quote 1
    • W
      Wayne Workman
      last edited by Apr 21, 2017, 12:18 AM

      I’m going to try this.

      Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG!
      Daily Clean Installation Results:
      https://fogtesting.fogproject.us/
      FOG Reporting:
      https://fog-external-reporting-results.fogproject.us/

      1 Reply Last reply Reply Quote 1
      • 1 / 1
      1 / 1
      • First post
        2/2
        Last post

      164

      Online

      12.1k

      Users

      17.3k

      Topics

      155.3k

      Posts
      Copyright © 2012-2024 FOG Project