Showing posts with label _samba. Show all posts
Showing posts with label _samba. Show all posts

Linux - share DVD-ROM through the LAN

Prerequisite: Samba has to be installed and I suppose that the hostname of your PC is MyPC.

Create a directory in /media
   sudo mkdir /media/DVD
 

Modify /etc/fstab by adding this line:
   /dev/sr0 /media/DVD iso9660 defaults,noauto,ro,user,uid=1000,gid=1000 0 0

   (one line)

Add (or check if it is already there) those lines in /etc/samba/smb.conf
   [DVD-ROM]
      path = /media/DVD
      browseable = yes
      read only = yes
      guest ok = yes
      locking = no
      preexec = /bin/mount /media/DVD
      postexec = /bin/umount /media/DVD
      writable = no

 

Reread /etc/fstab
   sudo mount -a 

   (ignore the errors that appears: it attempts to mount some already mounted devices)

Restart Samba
  sudo service smbd restart

Put a DVD/CD into the drive and check the share:
   in MAC
      Finder > Go > Connect to Server...
         type: smb://MyPC and press enter
         Select Guest as user name
   in Windows
      Open the File Explorer
      type \\MyPC and press enter

Windows 7 - doesn't print via Samba

Symptom

   Windows 7 refuse to print to a Samba shared printer, connected via Linux computer

 

Problem

    Windows didn't trust the print server's self-signed SSL certificate. 

 

My solution

  •    Use Firefox to navigate to https://[servername]:631
  •    It refuses. Trust the connection
  •    Now Firefox can open the CUPS Admin webpage, so the SSL exception is working
  •    Make note of the name of the printer to be installed
  •    Go to Start Menu/Devices and printers
  •    Click "Add a printer" / "add a network, wireless, or Bluetooth printer"
  •    Click "The printer that I want isn't listed
  •    Click the RadioButton next to "Select a shared printer by name"
  •    Enter, in the text box, http://[serverName or lan address]:631/printers/[printer name] (printer name must be the exact name listed on the CUPS admin webpage)
  •    Click next, and the printer should be ready to print