Hello,
anybody an idea how to prevent these errors:
Oct 17 10:33:01 mail zmconfigd[3640]: File "/opt/zextras/common/lib/jylibs/state.py", line 793, in rewriteConfig (fh, tmpfile) = tempfile.mkstemp(dir="/tmp")
Oct 17 10:33:01 mail zmconfigd[3640]: File "/opt/zextras/lib/jars/jython-standalone-2.5.2.jar/Lib/tempfile.py", line 302, in mkstemp return _mkstemp_inner(dir, prefix, suffix, flags)
Oct 17 10:33:01 mail zmconfigd[3640]: File "/opt/zextras/lib/jars/jython-standalone-2.5.2.jar/Lib/tempfile.py", line 236, in _mkstemp_inner fd = _os.open(file, flags, 0600)
Oct 17 10:33:01 mail zmconfigd[3640]: Rewrite failed: No such file or directory (No such file or directory)
Oct 17 10:33:01 mail zmconfigd[3640]: File "/opt/zextras/common/lib/jylibs/state.py", line 793, in rewriteConfig (fh, tmpfile) = tempfile.mkstemp(dir="/tmp")
Oct 17 10:33:01 mail zmconfigd[3640]: File "/opt/zextras/lib/jars/jython-standalone-2.5.2.jar/Lib/tempfile.py", line 302, in mkstemp return _mkstemp_inner(dir, prefix, suffix, flags)
Oct 17 10:33:01 mail zmconfigd[3640]: File "/opt/zextras/lib/jars/jython-standalone-2.5.2.jar/Lib/tempfile.py", line 236, in _mkstemp_inner fd = _os.open(file, flags, 0600)
Oct 17 10:33:01 mail zmconfigd[3640]: Rewrite failed: No such file or directory (No such file or directory)
Oct 17 10:33:01 mail zmconfigd[3640]: All rewrite threads completed in 0.02 sec
Oct 17 10:33:01 mail zmconfigd[3640]: All restarts completed in 0.00 sec
Oct 17 11:45:35 mail zmconfigd[1315]: File "/opt/zextras/common/lib/jylibs/state.py", line 796, in rewriteConfig for line in open(fr).readlines():
Oct 17 11:45:35 mail zmconfigd[1315]: Rewrite failed: [Errno 2] No such file or directory: '/opt/zextras/mailboxd/etc/zimbra.web.xml.in' ([Errno 2] No such file or directory: '/opt/zextras/mailboxd/etc/zimbra.web.xml.in')
Oct 17 11:45:35 mail zmconfigd[1315]: File "/opt/zextras/common/lib/jylibs/state.py", line 796, in rewriteConfig for line in open(fr).readlines():
Oct 17 11:45:35 mail zmconfigd[1315]: Rewrite failed: [Errno 2] No such file or directory: '/opt/zextras/mailboxd/etc/jetty-env.xml.in' ([Errno 2] No such file or directory: '/opt/zextras/mailboxd/etc/jetty-env.xml.in')
Running latest versions of all components.......
Hi @horizon,
please try to read old topics before open new one.
Here a possible solution : https://community.zextras.com/forum/postid/3850/
Next modify your /opt/zextras/conf/zmconfid.cf file , remove these lines :
SECTION zimbra REWRITE mailboxd/etc/zimbra.web.xml.in mailboxd/webapps/zimbra/WEB-INF/web.xml REWRITE mailboxd/etc/jetty-env.xml.in mailboxd/webapps/zimbra/WEB-INF/jetty-env.xml RESTART mailboxd SECTION zimlet REWRITE mailboxd/etc/zimlet.web.xml.in mailboxd/webapps/zimlet/WEB-INF/web.xml RESTART mailboxd
Then restart your zmconfigd service
I have executed: modify your /opt/zextras/conf/zmconfid.cf file , remove these lines :
Thanks
For information: Changing the file zmconfid.cf is indeed preventing the rewrite failures. However this needs to be done again after an upgrade of Carbonio. Would be better to change the file in the Carbonio sources.
you're right. I eliminated the recommended lines but now i've problem start zimbra sevice webapp... Failed.
zimbra webapp...Failed
zimbraAdmin webapp...Failed
zimlet webapp...Failed 🤔
Hi,
Fresh install Carbonio Release 22.12.0 in Ubuntu 20.04.5 LTS.
Same errors... how to solve?
Jan 10 23:07:10 carbonioh1 zmconfigd[1284]: Watchdog: service antivirus status is OK. Jan 10 23:07:10 carbonioh1 zmconfigd[1284]: File "/opt/zextras/common/lib/jylibs/state.py", line 793, in rewriteConfig (fh, tmpfile) = tempfile.mkstemp (dir="/tmp") Jan 10 23:07:10 carbonioh1 zmconfigd[1284]: File "/opt/zextras/lib/jars/jython-standalone-2.5.2.jar/Lib/tempfile.py", line 302, in mkstemp return _mkst emp_inner(dir, prefix, suffix, flags) Jan 10 23:07:10 carbonioh1 zmconfigd[1284]: File "/opt/zextras/lib/jars/jython-standalone-2.5.2.jar/Lib/tempfile.py", line 236, in _mkstemp_inner fd = _os.open(file, flags, 0600) Jan 10 23:07:10 carbonioh1 zmconfigd[1284]: Rewrite failed: No such file or directory (No such file or directory) Jan 10 23:07:10 carbonioh1 zmconfigd[1284]: File "/opt/zextras/common/lib/jylibs/state.py", line 793, in rewriteConfig (fh, tmpfile) = tempfile.mkstemp (dir="/tmp") Jan 10 23:07:10 carbonioh1 zmconfigd[1284]: File "/opt/zextras/lib/jars/jython-standalone-2.5.2.jar/Lib/tempfile.py", line 302, in mkstemp return _mkst emp_inner(dir, prefix, suffix, flags) Jan 10 23:07:10 carbonioh1 zmconfigd[1284]: File "/opt/zextras/lib/jars/jython-standalone-2.5.2.jar/Lib/tempfile.py", line 236, in _mkstemp_inner fd = _os.open(file, flags, 0600) Jan 10 23:07:10 carbonioh1 zmconfigd[1284]: Rewrite failed: No such file or directory (No such file or directory) Jan 10 23:07:10 carbonioh1 zmconfigd[1284]: File "/opt/zextras/common/lib/jylibs/state.py", line 793, in rewriteConfig (fh, tmpfile) = tempfile.mkstemp (dir="/tmp") Jan 10 23:07:10 carbonioh1 zmconfigd[1284]: File "/opt/zextras/lib/jars/jython-standalone-2.5.2.jar/Lib/tempfile.py", line 302, in mkstemp return _mkst emp_inner(dir, prefix, suffix, flags) Jan 10 23:07:10 carbonioh1 zmconfigd[1284]: File "/opt/zextras/lib/jars/jython-standalone-2.5.2.jar/Lib/tempfile.py", line 236, in _mkstemp_inner fd = _os.open(file, flags, 0600) Jan 10 23:07:10 carbonioh1 zmconfigd[1284]: Rewrite failed: No such file or directory (No such file or directory) Jan 10 23:07:10 carbonioh1 zmconfigd[1284]: File "/opt/zextras/common/lib/jylibs/state.py", line 793, in rewriteConfig (fh, tmpfile) = tempfile.mkstemp (dir="/tmp") Jan 10 23:07:10 carbonioh1 zmconfigd[1284]: File "/opt/zextras/lib/jars/jython-standalone-2.5.2.jar/Lib/tempfile.py", line 302, in mkstemp return _mkst emp_inner(dir, prefix, suffix, flags) Jan 10 23:07:10 carbonioh1 zmconfigd[1284]: File "/opt/zextras/lib/jars/jython-standalone-2.5.2.jar/Lib/tempfile.py", line 236, in _mkstemp_inner fd = _os.open(file, flags, 0600) Jan 10 23:07:10 carbonioh1 zmconfigd[1284]: Rewrite failed: No such file or directory (No such file or directory)
By specifying the name of a file as "filename.ext" when opening it with the open() function, you are indicating that the file is located in the current working directory. This type of file path is referred to as a relative path.
file = open('filename.ext') //relative path
In the above code, you are not giving the full path to a file to the open() function, just its name - a relative path. The error “FileNotFoundError: [Errno 2] No such file or directory” is telling you that there is no file of that name in the working directory. So, try using the exact, or absolute path.
file = open(r'C:\path\to\your\filename.ext') //absolute path
In the above code, all of the information needed to locate the file is contained in the path string - absolute path.
If the user fails to provide a full path to the file (which, on Unix-like systems, means a path starting with a slash), Python interprets the file path relatively to the current working directory. Typically, the current working directory is the directory where the program was launched from. For this to work correctly, the directory containing the Python executable must be listed in the PATH environment variable, which contains a set of directories that the system searches when searching for executable files. Regardless, if your Python script file and the input data file are not located in the same directory, you will need to specify either a relative path between them or use an absolute path for one of the files.
The error messages you provided indicate that the program or script is trying to access certain files or directories that do not exist. Here are a few suggestions to prevent these errors:
1. Verify File and Directory Paths: Double-check that the file paths mentioned in the error messages are correct. Ensure that the specified files and directories exist in the expected locations. Make sure there are no typographical errors or missing directories.
2. Permissions: Check the permissions of the files and directories involved. Ensure that the program or script has the necessary read and write permissions to access and modify the files. You may need to adjust the permissions using the `chmod` command.
3. Configuration Files: If the missing files are configuration files, ensure that they have been correctly installed or provided. Check if there are any installation steps or configuration steps that you might have missed.
4. Dependencies: Verify that any required dependencies or libraries are properly installed and accessible. The program or script may rely on certain libraries or modules that need to be present in the system.
5. Software Updates: Ensure that you are using the latest version of the software or script that generates these errors. Check if there are any updates or patches available that address known issues or bugs.
6. Support: If you are using a specific software or script, reach out to the support channels or documentation for that particular software. They may be able to provide additional troubleshooting steps or offer specific guidance related to the errors you are encountering.