Skip to content

Troubleshooting


Invalid SSL Certificate in SEAL MongoDB

If your system crashes with a fatal assertion 28652, the reason may be an invalid SSL certificate for SEAL MongoDB.

Check the validity of the SSL certificate as follows:

  1. In an editor, open the MongoDB configuration file:

    • Linux:

      /opt/seal/etc/mongod.conf
      
    • Windows:

      "C:\ProgramData\SEAL Systems\config\mongod.conf"
      
  2. Replace the line:

    CAFile: C:\ProgramData\SEAL Systems\config\tls\ca.pem
    

    by the following line:

    allowInvalidCertificates: true
    
  3. Save the configuration file.

  4. Restart MongoDB:

    • Linux:

      sudo systemctl restart mongod
      
    • Windows:

      restart-service seal-mongodb
      

If you can verify the problem this way, continue as follows.

Solution:

  1. Check, whether the date is set correctly in the system time.

  2. Check the validity of the PEM file.

    Hint - checking PEM files

    You can use the openssl commands to explore the details of a certificate, e. g.

    openssl x509 -in mycert.pem -text -noout
    

    If you do not have installed openssl, you can use a web tool to check the certificate.

  3. If necessary, replace the the invalid certificate file with a new PEM file.

  4. Undo the previous temporary changes in the SEAL MongoDB configuration file.

  5. Restart MongoDB.


Other MongoDB TLS Certificate Errors

Check the MongoDB log file for the exact error message:

  • Linux:

    /var/log/seal/mongod.log
    
  • Windows:

    "C:\ProgramData\SEAL Systems\log\mongod.log"
    

The following list shows error messages an their causes:

  • Can not set up PEM key file.:

    The file referenced by certificateKeyFile is invalid.

    It has to contain both, the certificate and the private key, see "TLS Encryption" on Linux or Windows.

  • The use of both a CA File and the System Certificate store is not supported.:

    CAFile and tlsUseSystemCA are both defined in mongod.conf.

    Remove tlsUseSystemCA from the setParameter section.

  • The use of TLS without specifying a chain of trust is no longer supported ...:

    The root certificate is missing.

    For details on the CA Certificate, see "Specifying a CA Certificate" on Linux or Windows.


MongoDB Allocates too Much Disk Space

MongoDB gets too big, because it does not automatically release unneeded disk space to the operating system.

Solution:

The compact database command attempts to reduce the disk space, see original documentation.


Disk Full on a MongoDB Cluster Member

If a MongoDB cluster member runs out of disk space, restart the cluster as described below.

Hint - keep the order

Mind the order of the action to avoid synchronization problems.

  1. Stop all SEAL products that use this MongoDB installation.

  2. Stop MongoDB, on all servers in the cluster.

    • Linux:

      sudo systemctl stop mongod
      
    • Windows:

      Stop-Service -name seal-mongodb -Force
      
  3. Increase the disk space.

  4. Start MongoDB on every server in the cluster.

    • Linux:

      sudo systemctl start mongod
      
    • Windows:

      Restart-Service -name seal-mongodb -Force
      
  5. Check, whether all servers are synchronized:

    sudo mongosh --tls --tlsAllowInvalidCertificates --eval 'printjson(rs.status())'
    
  6. As soon as all servers are sychronized, restart the SEAL products on every server in the cluster.


MongoDB Cluster Member Stuck in Recovering

If a MongoDB cluster member permanently shows the RECOVERING status in rs.status(), it cannot synchronize anymore.

This may happen after a longer server failure.

Force a full resynchronization on the affected server:

Caution - only from the most up to date member

Resync from the most up to date member in the replica set to prevent data loss.

For details on the resnchronization see original documentation.

  1. Stop all SEAL products that use this MongoDB installation.

  2. Stop MongoDB on the affected server.

    • Linux:

      sudo systemctl stop mongod
      
    • Windows:

      Stop-Service -name seal-mongodb -Force
      
  3. On the affected server, delete all files in the MongoDB data directory:

    • Linux:

      /opt/seal/data/seal-mongodb
      
    • Windows:

      "C:\ProgramData\SEAL Systems\data\seal-mongodb"
      

    Caution - data only

    Delete only the files in the data directory. Do not delete the directory itself.

  4. Start MongoDB on the affected server.

    • Linux:

      sudo systemctl start mongod
      
    • Windows:

      Restart-Service -name seal-mongodb -Force
      
  5. Check, whether the RECOVERING status rs.status() has disappeared for this server.

    Depending on the amount of data and the network latency between the cluster members, this may take 10 to 15 minutes or even longer.

  6. Restart the SEAL products on every server in the cluster.

    • Linux:

      sudo systemctl start mongod
      
    • Windows:

      Restart-Service -name seal-mongodb -Force
      

Back to top