Had some problems with WordPress and its pseudo-cron function - we think. Logs were filling very rapidly.
Sysadmin advised turing of wp-cron functionality per this site.
I've done this on cgtw and etcl only.
I've added a couple features to the upyerdb script.
I've removed the need for a remote script that determines the last modified timestamp. It now gets sent as part of the curl request and the script is embedded in the upyerdb script itself.
Also added a feature that excludes all files not under SVN control from being uploaded. This reduces the amount of rubbish that gets pushed to the DB.
The script is *just* finished and needs testing in a safe environment - not for production use.
Two ways to serve up static files that are not in the context of the controller.xql:
if (contains($currentUri, 'pix/')) then <dispatch xmlns="http://exist.sourceforge.net/NS/exist"> <forward absolute="no" url="{concat('/../data/pix/', $exist:resource)}"/> </dispatch>
if (contains($currentUri, 'graphics/')) then <dispatch xmlns="http://exist.sourceforge.net/NS/exist"> <forward absolute="yes" url="{concat('/rest/db/data/graphics/', substring-after($currentUri, 'graphics/'))}"/> </dispatch>
This is commonly used when e.g. the site logic and controller are in /db//site (which may be mapped to a subdomain), controlled by admin, while the content needs to be controllable by editors (so it's in e.g. a /db/data). I've had to re-figure this out a couple of times, so I'm blogging it for future reference.
Running ./build.sh dist-war I get two errors:
1) BUILD FAILED $home/exist/build/scripts/dist.xml:35: $MYBUILDDIR/extensions/indexes/spatial/lib does not exist.
2) BUILD FAILED $home/exist/build/scripts/dist.xml:35: $MYBUILDDIR/extensions/betterform/main/xrx does not exist.
The problem is that the $home/exist/extensions/indexes/spatial/lib/ and $home/exist/extensions/betterform/main/xrx/ directories do not exist. Manually creating them before running dist-war stops the errors from recurring.
After a conversation with Martin about why there's no flag for 'ls' that retrieves permissions in octal form, I added an alias to do this for me.
To create the alias, do this:
alias oct="stat -c '%A[%a] %U:%G %s %.19z %n' $1"
Then, run it like this:
oct /usr/bin/*
and get back something like this:
-rwxr-xr-x[755] root:root 17792 2014-06-03 15:24:04 /usr/bin/xkbvleds
-rwxr-xr-x[755] root:root 16096 2014-06-03 15:24:04 /usr/bin/xkbwatch
-rwxr-xr-x[755] root:root 14659 2014-06-03 15:24:04 /usr/bin/xkeystone
-rwxr-xr-x[755] root:root 14640 2014-06-03 15:24:04 /usr/bin/xkill
-rwxr-xr-x[755] root:root 16016 2014-06-03 15:24:04 /usr/bin/xload
Last night we upgraded Tomcat on peach to the latest version in order to take advantage of some recent GC optimizations. Unfortunately it also included a security fix that broke all of our Cocoon apps. So, bcgenesis, mariage, ach, myndir, etc. were dead.
Sysadmin fixed some of them with an adjustment to the web.xml file inside of each app like this:
Around line 708 in <app-name>/WEB-INF/web.xml, look for
<servlet-mapping>
<servlet-name>WebDAVServlet</servlet-name>
<url-pattern>/webdav/*</url-pattern>
</servlet-mapping>
and change webdav/* to something else, like webdavservlet/*
I have a bunch of new users to add to the system and make members of the CanMys blog. When I added the first and logged in as him, I noticed that when I clicked on the Posts button, I was allowed to see posts from the Moses, EMCS and Scraps blogs. Turns out those three blogs had group permissions which made all users of type "Blogger" members and with permission to upload to the media folder, but do nothing else. Those three blogs also have individual users with specific permissions.
I disabled the is-member checkbox for Bloggers in the group permissions for each of those three blogs. That automatically disabled the upload checkbox. There should be no change of behaviour for specific users that are members of those blogs.
To fix this problem, run
sudo update-alternatives --config javaws
and choose the java 7 version
NOTE: OpenJDK doesn't come with javaws by default. You need to install the 'icedtea-7-plugin' before you can do the config bit above.
The ISE was getting the error
java.lang.NoClassDefFoundError: Could not initialize class sun.awt.X11GraphicsEnvironment
when running xwiki.
It turns out that the existence of quotes in JAVA_OPTS directives causes the option to be ignored. So, for future reference, use -Djava.awt.headless=true
instead of -Djava.awt.headless="true"
when launching tomcat on a headless server.
After an update to DSM 4.2 rutabaga no longer allowed rsync backups, failing with:
sh: rsync: not found
rsync: connection unexpectedly closed (0 bytes received so far) [Receiver]
rsync error: remote command not found (code 127) at io.c(605) [Receiver=3.0.9]
After much wailing and gnashing of teeth we discovered that non-interactive users do not have /usr/syno/bin in their path (it *is* in their path if they shell in to the NAS, so they can run rsync *from* the NAS when shell'd in).
So, that's an easy fix, says us: add a symlink to /usr/syno/bin/rsync in a logical spot that *is* in a non-interactive path, like /usr/bin.
Problem: admin user cannot su root (error message = su: must be suid to work properly), so cannot create symlink.
Answer: TURN ON TELNET AND LOG IN AS ROOT USING THE WORST POSSIBLE METHOD!!! Then, you make the symlink and turn off telnet - quick!