Skip to main content

Share Management

This section provides an overview of managing shares in Fusion File Share Server.

The shares discussed in this section refer to file system directories. For information on printer shares, see Printers.

Share management can also be performed using the Microsoft Management Console (MMC) snap-in. For more information, see Configuring using the Microsoft Management Console (MMC).

Adding a Share

A share can be added to Fusion File Share Server through either the configuration file or the command line interface (CLI).

Adding a Share Using the Configuration File

To add a share using the configuration file, follow these steps:

  1. Edit the configuration file:

    Open the configuration file in a text editor.

  2. Add the share configuration:

    Add a new [share] section to the configuration file.

    important

    The [share] sections MUST be placed below the [global] section.

    The most basic configuration parameters for a share are:

    Share Parameter The Name of the Share

    Value Type: string

    Default Value: none.

    Examples:

    • sh1 sets the net name to sh1.
    • MyShare sets the net name to MyShare.
    Share Parameter The Path to Share

    Value Type: string

    Value Format: <path>
    Where <path> is:

    • For shared directories: The directory on the server's file system to be shared.
    • For printer shares: The name of the print queue.

    Default Value: none.

    Examples:

    • /export/sh1, if the share type is disk, indicates that the shared directory is /export/sh1.
    • paperjam, if the share type is printer, indicates that the print queue is called paperjam.

    For advanced share configuration parameters, refer to the SMB Features and Setting and Authorization and Access Management sections where some topics address specific share behavior. For a complete list of share configuration parameters, see the share configuration reference.

    The following example shows a simple share configuration:

    [share]
    netname = MyShare
    path = /export/share
    [/share]

    This example creates a share named MyShare that shares the files in /export/share. Since no permissions are specified, the share will have default permissions (read to everyone).

  3. Save the configuration and restart Fusion File Share Server:

    To apply the changes you've made, save the configuration file and restart the Fusion File Share Server process.

Adding a Share Using the CLI

It is possible to add a share using command line tools. You'll use tsmb-cfg to configure a new share, and tsmb-server to persist the changes.

note

Using the CLI to configure a share is only possible if the Fusion File Share Server is running.

important

Configuration changes made with the CLI are not persisted across server restarts, unless Fusion File Share Server is started in persistent configuration mode.

To add a share using the CLI, use the tsmb-cfg share add command to add a new share. The following parameters are required for adding a share:

  • -n or --name: The name of the share.
  • -p or --path: The path on the Fusion File Share Server that you want to share. This must be a valid path on the server.

For more advanced share configuration parameters, refer to the tsmb-cfg share add reference for a complete list of share parameters.

For example, assuming tsmb-cfg is in your $PATH:

sudo tsmb-cfg share add -n MyShare -p /export/share

This command creates a share named MyShare that shares the files in /export/share, with default permissions (read access for everyone).

Removing a Share

You can remove a share from Fusion File Share Server using the configuration file or the CLI.

Removing a Share Using the Configuration File

To remove a share using the configuration file, follow these steps:

  1. Edit the configuration file:

    Open the configuration file (typically, /etc/tsmb.conf) in a text editor.

  2. Delete the share configuration:

    Delete the [share] section that corresponds to the share you want to remove.

  3. Save the configuration and restart Fusion File Share Server:

    To apply the changes you've made, save the configuration file and restart the Fusion File Share Server process.

Removing a Share Using the CLI

To remove a share using the CLI, use tsmb-cfg.

note

Using the CLI to configure a share is only possible if the Fusion File Share Server is running.

important

Configuration changes made with the CLI are not persisted across server restarts unless Fusion File Share Server is started in persistent configuration mode.

To remove a share using the CLI, use the tsmb-cfg share del command to remove a share. The following parameters are required:

  • -n or --name: The name of the share you want to remove.

For example, assuming tsmb-cfg is in your $PATH:

sudo tsmb-cfg share del -n MyShare

This command removes the share named MyShare.

Updating a Share

You can update a share in Fusion File Share Server in the following ways:

  • Using the configuration file:

    You can update a share's parameters using the configuration file. In this case, you can modify any parameter, however a server restart is required to apply the changes.

  • Using the CLI:

    You can update a share's parameters using the CLI. However, you can only do it while the Fusion File Share Server is Running, and only certain parameters can be modified.

Updating a Share Using the Configuration File

To update a share using the configuration file, follow these steps:

  1. Edit the configuration file:

    Open the configuration file in a text editor.

  2. Update the share configuration:

    Edit the [share] section that corresponds to the share you want to update.

  3. Save the configuration and restart Fusion File Share Server:

    To apply the changes you've made, save the configuration file and restart the Fusion File Share Server process.

Updating a Share Using the CLI

note

Using the CLI to configure a share is only possible if the Fusion File Share Server is running.

important

Configuration changes made with the CLI are not persisted across server restarts, unless Fusion File Share Server is started in persistent configuration mode.

To update a share using the CLI, use the tsmb-cfg share update command to update a share. The following parameters are required:

  • -n or --name: The name of the share you want to update.
  • Any parameter you want to update, such as -n (for the share's name) or --remark for the share's comment, etc. For a complete list of parameters you can update while the Fusion File Share Server is running, see the tsmb-cfg share update reference.

For example, assuming tsmb-cfg is in your $PATH:

sudo tsmb-cfg share update -n MyShare --hidden true

This command modifies the share named MyShare, to mark it as hidden.