| Commit message (Collapse) | Author | Age |
| |
|
|
|
|
|
|
|
|
|
|
|
| |
This essentially reverts commit 66cdd5bc99a5 which aimed to make the
dss log facility C89 conform. While this was a worthwhile goal in
2012, it has little value today, since in 2025 we can safely assume
a C99 compliant compiler.
The patch was created with
git revert -Xours 66cdd5bc
followed by manual tweaks to make it compile again.
|
| |
|
|
|
|
| |
The doxygen comments actually make the source code harder to read,
because they tend to document the obvious. Besides, they are not used
uniformly accross the code base anyway.
|
| | |
|
| |
|
|
|
| |
It's sometimes handy to just type e.g. "dss help run" to see the
synopsis and the options of the ls subcommand.
|
| |
|
|
| |
For users which can't be bothered to use git or compile from source.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We currently pass a number of variables to m4 by specifying command
line options of the form -D var=val. This approach makes the output of
"make V=1" very verbose due to the three multi-line descriptions. To
addresses this issue, introduce defs.m4 which contains one m4 macro
definition for each former make variable. The end result should
be identical.
We tweak the M4 make variable to always read defs.m4 before the
first regular input file so that the suite and the web page see the
definitions. The third user of the former make variables is the README
phony target. To convert this as well, we rename the README file to
README.m4 and adjust the rule of the README phony target to run m4
on this file.
Switch to saner m4 quoting characters while at it.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Since the new section contains a table, we have to tell groff to run
the tbl preprocessor to generate the html version of the man page.
We now pass -I image to the groff postprocessor so that
the png image file gets a predictable name. We'd love to
pass --image‐directory=build/ to place the png file in
the build directory, but this also creates html like <img
src="build/image1.png">, which does not work because index.html is
in build/. Change the cwd to the build directory to work around this.
|
| |
|
|
|
|
| |
With the patch applied, "make clean" keeps files generated by lopsub
and m4, "make distclean" removes the build directory, and "make
maintainer-clean" removes all untracked files except Makefile.local.
|
| |
|
|
|
|
| |
This way the web page can be installed by copying a single html file.
It also speeds up page loading since no additional http request is
needed to download the image file.
|
| |
|
|
|
| |
This saves some typing as the simple "make www" now builds index.html
and the html version of the man page.
|
| |
|
|
| |
There's no reason for this to be after the README stuff.
|
| |
|
|
|
| |
This way the intermediate files don't clobber the top level of the
working directory. Also the clean phony target becomes simpler.
|
| |
|
|
|
| |
At least on some firefox versions, the characters of the default
monospace font look a bit small.
|
| |
|
|
| |
This looks much better. We don't want that for table cells, though.
|
| |
|
|
|
|
| |
The page has become simple enough, making the navigation links useless.
The page no longer contains any <hr> tags, so remove the corresponding
part of the style sheet.
|
| |
|
|
|
| |
This should speed up page loading because it saves the additional
http connection to the web server to download dss.css.
|
| |
|
|
|
|
|
|
|
| |
It's not like the dss project saw lots of news lately, and the old
news items only clutter the web page. This removes the last invocation
of markdown(1), making the build independent of the discount converter.
We keep maintaining the NEWS file in the repo, however. It's just no
longer part of the web page.
|
| |
|
|
| |
This avoids index.html.in and parses index.html.m4 only once.
|
| |
|
|
|
|
|
|
| |
Move the installation instructions to index.html.m4 and the
configuration bits to the new examples section of the man page.
Streamline the installation instructions and recommend to install the
debian package of lopsub.
|
| |
|
|
|
|
| |
This shortens index.html and simplifies the build because we can
ditch the sed command which cuts out the body of the html generated
by groff(1).
|
| |
|
|
|
| |
No need to have a full section for a single sentence. Just add an
item in the resource section which states the same information.
|
| |
|
|
|
|
|
|
|
| |
This defines a couple of package related variables in Makefile,
renames dss.suite -> dss.suite.m4 and index.html.in -> index.html.m4,
and tweaks the recipes to generate dss.suite and index.html.in from
the m4 files, referring to these variables. The contents of the
README file are moved into Makefile so that the three paragraphs can
be printed with make README.
|
| |
|
|
|
| |
This streamlines the text to some extent, omitting the comparison to
tape backups, which is not really interesting for most users.
|
| |
|
|
| |
Run gzip with -n to make the build reproducible.
|
| |
|
|
|
|
| |
Without having the .PRECIOUS special target depending on these, the
files get removed after a successful build and a subsequent make run
has to rebuild them.
|
| | |
|
| |
|
|
|
|
|
| |
This teaches make(1) to give all lines of the recipe to a single
shell invocation, speeding up the build and facilitating the simple
SAY function to quieten the build. The old verbose output can still
be obtained by running make V=1.
|
| |
|
|
|
|
|
| |
This gets rid of Makefile.deps in favor of one auto-generated .d
file per .c file, and adds version-gen.sh, a shell script executed
by make(1) which tries to determine the version number that is going
to be incorporated into the executable via the generated version.c.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Quiting getpwnam(3):
An application that wants to determine its user’s home
directory should inspect the value of HOME (rather than the value
getpwuid(getuid())->pw_dir) since this allows the user to modify
their notion of "the home directory" during a login session.
The old behaviour of get_homedir() to return "/tmp" in the error case
is misleading at best, so abort in this case.
|
| |
|
|
|
| |
Nobody has ever used this, and the build gets never tested with
non-default compile time loglevel, so...
|
| |
|
|
|
| |
It's easier if dss.c passes the hash of the the config file path to
the ipc functions than to pass a char pointer.
|
| |
|
|
|
|
|
|
| |
Currently we call get_config_file_name() before each call call to a
public function of ipc.c because those functions compute the IPC key
from the filename. This is unnecessary and caused several bugs. Clean
up this mess by computing the filename only once and store it in a
global variable.
|
| |
|
|
|
| |
These days we may rely on the POSIX 2008 semantics of this function,
so remove our open-coded version.
|
| |
|
|
|
|
| |
These additional targets are handy for site-local targets such as
installing the web files or deploying the executable and the man page
on a remote server.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The dss lock works by first turning the given config file path
argument into a canonical absolute path using dss_realpath(), then
hashing this absolute path to obtain a key ID for semget(2).
If the given path is relative, we have to compute the ID before
changing to the destination directory because dss_realpath() needs to
call stat(2) to detect symlinks, and this system call will fail if the
current working directory has changed. This is currently not the case
as we change to the destination directory early in check_config().
If dss_realpath() fails, we silently use the unmodified path argument
for hashing to deal with the case that the default config does not
exist. As a result, if relative paths are given, the key ID depends
on whether or not change_to_dest_dir() was called. This is the case
for the run subcommanmd, but not for the kill subcommand. Thus the
kill subcommand does not work as expected if a relative path is given.
Fix this by grabbing the lock before changing the working directory
in all cases.
|
| |
|
|
|
|
| |
If parse_config_file() encounters an error, it logs the error *and*
returns the error code, which causes the error message to be logged
again. Fix this by removing the log statement from parse_config_file().
|
| | |
|
| |\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
A couple of cleanups and unifications for the snapshot pruning code,
which is executed by the prune and run subcommands. With the patches
applied, both subcommands behave identically, i.e. they consider
the same set of snapshots as candidates for pruning. Also the prune
command gained the new --disk-space option to force it to act as if
disk space was high or low.
Cooking for six weeks.
* refs/heads/t/prune:
Introduce prune --disk-space.
Revamp com_prune().
Factor out find_removable_snapshot().
prune Simplify rm exit code logic.
find_oldest_removable_snapshot(): Improve log message.
prune: Print a message if there is nothing to prune.
get_snapshot_list(): Add comment about sorting.
prune: Fail gracefully if pre-rm hook fails.
|
| | |
| |
| |
| |
| |
| |
| | |
The new option takes a mandatory argument of the set {check, high,
low}. The latter two make the command act as if disk space was
high/low without actually performing the check. This is mostly useful
for debugging.
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The prune subcommand implements its own logic for picking the snapshot
to remove. The algorithm is similar but not identical to how the run
subcommand gets rid of snapshots.
This patch eliminates this inconsistency by changing com_prune()
to call the find_removable_snapshot() helper which was introduced in
the previous commit.
Since find_removable_snapshot() returns a dynamically allocated string
via the "why" pointer, we have to introduce another label for freeing
this memory.
The patch also improves the help text of the prune subcommand slightly.
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Both the run and the prune subcommand contain code for picking a
suitable snapshot to remove, with slightly different semantics.
This is a preparatory patch for eliminating the differences between
the two implementations. It introduces a new helper which can be
shared. After this patch, only the run subcommand uses the helper. A
subsequent patch will convert the second caller, com_prune().
|
| | |
| |
| |
| |
| | |
We can rely on the fact that wait_for_remove_process() sets
snapshot_removal_status to the correct value on success.
|
| | |
| |
| |
| |
| |
| | |
The other three functions which return a candidate for removal print
one debug message but not the name of the selected snapshot, so make
find_oldest_removable_snapshot() follow this pattern too.
|
| | |
| |
| |
| |
| |
| | |
When the prune subcommand finds there are no snapshots to prune, the
command stays silent, which is confusing. Make it print "nothing to
prune" in this case.
|
| | |
| |
| |
| |
| | |
Callers rely on the returned snapshot list being sorted by creation
time, so let's document this fact.
|
| | |
| |
| |
| |
| |
| | |
In this case wait_for_remove_process() returns non-negative and we
miss to set the exit code, making the command appear to succeed even
if the rm process has not been created.
|
| |\ \
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Cooking for about a month. The web page has been updated today to
use the new logo.
* refs/heads/t/svg-logo:
Redo the logo as svg.
|
| | |/
| |
| |
| |
| |
| |
| |
| |
| | |
Scalable vector graphics are much nicer for web pages than bitmaps. The
mklogo script can be removed and there is no more dependency on
ImageMagick. What a deal.
The new logo was made with vi. It is a bit smaller than the old logo
but looks similar.
|
| | |
| |
| |
| |
| |
| |
| |
| |
| | |
We don't need this because we actively want rsync to respect the file
creation mask. This does not matter in the common case of a single
source directory because the permission bits will be copied from the
source directory anyway. However, for multiple source directories it
does matter because with umask(0) the top level snapshot directory
is created with mode 777.
|
| | |
| |
| |
| |
| |
| | |
This bug was introduced recently in commit dd3f58c0bdf1
(create_rsync_argv(): Allocate correctly sized arg array) which
redefined N.
|