User Tools

Site Tools


cobi.wms:service_layer_uploads

Service Layer Uploads

Uploading document attachments or item master images via Service Layer often requires some additional configuration on the server on which Service Layer is running. (Typically, the SLES/HANA server.) Here are the necessary steps, using the Attachments folder as an example; they should all be executed as the root user.

1. Create a directory that will be used as the mount-point: mkdir /mnt/sbo-attachments

2. Edit the file /etc/fstab and add a line such as the following:

//path/to/attachments /mnt/sbo-attachments cifs uid=b1service0,cred=/root/.sbo-atc-cred 0 0

This assumes that Service Layer runs under the local Unix user b1service0 (see uid= part). If this is not the case on your server, then change that part of the line to the correct user.

The //path/to/attachments part represents a network file share path corresponding to the location of the Attachments folder. It must be exactly equal to the value in the corresponding configuration field in the SAP Business One settings except that here you have to use forward-slashes (/) instead of backslashes (\) to separate the parts of the path. Make sure that everything is exactly equal apart from the different slashes. For example, you can't use an IP address in one place and a host name in the other.

If you have to use a host name in the network path but it doesn't resolve properly on the server, you can add a line to /etc/hosts like this:

10.0.0.1 myhostname

In this example the IP address is 10.0.0.1 and the host name myhostname is used in the network path, like for example:

//myhostname/B1_SHF/Attachments

3. Create the file /root/.sbo-atc-cred which we referenced in the newly added /etc/fstab line above. The format of this file is as follows and should specify the login credentials of a domain user that can access the network file share:

user=myusername
password=mypassword
domain=mydomain

Make sure that the file is protected by changing its permissions to be only readable by the root user:

chmod 600 /root/.sbo-atc-cred

4. The line in /etc/fstab will ensure that the folder is mounted when the system reboots, but to make the line take effect immediately without a reboot you can run the command: mount -a

You can see all the currently active mount-points by running the command mount without any parameters. Verify this way that the line in /etc/fstab works correctly.

5. On some systems, a network path in /etc/fstab may fail to mount during reboot, for example if the system tries to activate it before the network connection is activated. The correct way to solve this is to reconfigure the boot process to take this into account, but this may be complicated. A simple workaround is putting the command mount -a in a file that will be executed at the end of the boot process, such as /etc/rc.local or /etc/init.d/boot.local depending on the exact operating system and version.

cobi.wms/service_layer_uploads.txt · Last modified: 2022/10/24 16:03 by tkammer

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki