Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The solution is to increase the system-wide limit on the number of open files. The exact procedure, however, varies from one OS to the next, see Too many open files.

Expand
titleUbuntu Linux
  1. Find the current maximum number of open files per user in a single session: 
    ulimit -n
    By default the number is 1024 which is too small.
  2. Edit the limits.conf file: 
    sudo gedit /etc/security/limits.conf
  3. Add the following lines to the file: 
    * soft nofile 10000
    * hard nofile 50000
    This sets for all users a soft limit of 10000 open files and a hard limit of 50000. These are just example numbers. Set them according to your system needs. Note that the wildcard option applies only to regular users, not to superuser. If you run Magnolia as superuser replace the asterisk with root.
  4. Save the file.
  5. Edit the configuration file for session-related modules: 
    sudo gedit /etc/pam.d/common-session
  6. Add the following line to the file: 
    session required pam_limits.so

    Info

    On *ubuntu 17.04 you'll probably also have to add the following line

    DefaultLimitNOFILE=65535

    to /etc/systemd/system.conf

    and to /etc/systemd/user.conf .

    See Cannot Increase open file limit past 4096 (Ubuntu).

  7. Save the file.
  8. Restart Ubuntu.
  9. Verify the new maximum number of open files: 
    ulimit -n
    The command should now return 10000.


...

Info

If you want to run two different Tomcats simultaneously you need to change other ports too. This is useful if you want to run different versions of Magnolia at the same time. In <CATALINA_HOME>/conf/server.xml, change the port numbers for the shutdown and AJP sections and any custom sections you have enabled.

Windows Firewall is blocking Java

Allow an exception in Windows Firewall for Java.

  1. Go to Control Panel > Windows Firewall.
  2. Go to the Exceptions tab.
  3. Click Add Program and browse to the java.exe file in the Java installation directory, for example C:\Sun\SDK\jdk\bin\java.exe.
  4. Click OK.

If you get a security alert during startup, check the Private networks checkbox and click Allow access.

Cannot publish content with path-based locking

After upgrading to Magnolia 5.7.9, it is not possible to publish content locally. The following errors can be found in the logs:

Log of the Author instance

Code Block
ERROR info.magnolia.publishing.command.PublicationCommand 08.06.2021 09:42:18 – Receiver: magnoliaPublic8080, error: Unable to contact receiver, HTTP response code: 500.

Log of the Public instance

Code Block
ERROR info.magnolia.publishing.receiver.operation.jcr.AbstractJcrReceiveOperation 08.06.2021 09:41:52 – UNC path is missing sharename: /\website\/
java.nio.file.InvalidPathException: UNC path is missing sharename: /\website\/

As a temporary workaround, switch the locking mode to compatibility (JCR-based) locking in the configuration of the publishing-core module:

/modules/publishing-core/config@lockManagerMode=compatibility

Windows Firewall is blocking Java

Allow an exception in Windows Firewall for Java.

  1. Go to Control Panel > Windows Firewall.
  2. Go to the Exceptions tab.
  3. Click Add Program and browse to the java.exe file in the Java installation directory, for example C:\Sun\SDK\jdk\bin\java.exe.
  4. Click OK.

If you get a security alert during startup, check the Private networks checkbox and click Allow access.

CATALINA_HOME environment variable is not defined

...

Jira
PAGES-145
serverMagnolia - Issue tracker
columnskey,summary,type,created,updated,due,assignee,reporter,priority,status,resolution
serverId500b06a6-e204-3125-b989-2d75b973d05f
key
tracker
columnskey,summary,type,created,updated,due,assignee,reporter,priority,status,resolution
serverId500b06a6-e204-3125-b989-2d75b973d05f
keyPAGES-145

Natural order not respected in results of content searches

If you search for content using searchfn.searchPage(), searchfn.searchContent() or by executing search queries directly from a template, the search result order will not respect the natural order. This issue is caused by a bug in Apache Jackrabbit filed as JCR-3932: "Result of JCR-SQL2 query doesn't respect document order in JCR".

Until the JCR bug is fixed, do not use searchfn. To get the correct order, execute JCR XPath queries directly.