History log of /freebsd-current/sbin/hastd/parse.y
Revision Date Author Comments
# b3e76948 16-Aug-2023 Warner Losh <imp@FreeBSD.org>

Remove $FreeBSD$: two-line .h pattern

Remove /^\s*\*\n \*\s+\$FreeBSD\$$\n/


# 4d846d26 10-May-2023 Warner Losh <imp@FreeBSD.org>

spdx: The BSD-2-Clause-FreeBSD identifier is obsolete, drop -FreeBSD

The SPDX folks have obsoleted the BSD-2-Clause-FreeBSD identifier. Catch
up to that fact and revert to their recommended match of BSD-2-Clause.

Discussed with: pfg
MFC After: 3 days
Sponsored by: Netflix


# 1de7b4b8 27-Nov-2017 Pedro F. Giffuni <pfg@FreeBSD.org>

various: general adoption of SPDX licensing ID tags.

Mainly focus on files that use BSD 2-Clause license, however the tool I
was using misidentified many licenses so this was mostly a manual - error
prone - task.

The Software Package Data Exchange (SPDX) group provides a specification
to make it easier for automated tools to detect and summarize well known
opensource licenses. We are gradually adopting the specification, noting
that the tags are considered only advisory and do not, in any way,
superceed or replace the license texts.

No functional change intended.


# eb8b73d6 22-May-2013 Jung-uk Kim <jkim@FreeBSD.org>

Improve compatibility with old flex and fix build with GCC.


# d6e636c9 17-Feb-2013 Pawel Jakub Dawidek <pjd@FreeBSD.org>

- Add support for 'memsync' mode. This is the fastest replication mode that's
why it will now be the default.
- Bump protocol version to 2 and add backward compatibility for version 1.
- Allow to specify hosts by kern.hostid as well (in addition to hostname and
kern.hostuuid) in configuration file.

Sponsored by: Panzura
Tested by: trociny


# a5752d55 21-Dec-2012 Kevin Lo <kevlo@FreeBSD.org>

Fix socket calls on error post-r243965.

Submitted by: Garrett Cooper


# 5e2a209a 22-May-2012 Baptiste Daroussin <bapt@FreeBSD.org>

Fix world after byacc import:
- old yacc(1) use to magicially append stdlib.h, while new one don't
- new yacc(1) do declare yyparse by itself, fix redundant declaration of
'yyparse'

Approved by: des (mentor)


# e0a8ef9d 04-Feb-2012 Pawel Jakub Dawidek <pjd@FreeBSD.org>

Fix typo in comment.

MFC after: 3 days


# 2ce9c023 21-Jan-2012 Pawel Jakub Dawidek <pjd@FreeBSD.org>

Fix minor memory leak.

MFC after: 3 days


# ba1fa0f1 20-Jan-2012 Pawel Jakub Dawidek <pjd@FreeBSD.org>

Remove another unused token.

MFC after: 3 days


# 77213228 20-Jan-2012 Pawel Jakub Dawidek <pjd@FreeBSD.org>

Remove unused token 'port'.

MFC after: 3 days


# 07ebc362 27-Oct-2011 Pawel Jakub Dawidek <pjd@FreeBSD.org>

Implement 'async' mode for HAST.

MFC after: 3 days


# bd738d63 16-Oct-2011 Pawel Jakub Dawidek <pjd@FreeBSD.org>

Allow to specify pidfile in HAST configuration file.

MFC after: 1 week


# 12daf727 28-Sep-2011 Pawel Jakub Dawidek <pjd@FreeBSD.org>

If the underlying provider doesn't support BIO_FLUSH, log it only once
and don't bother trying in the future.

MFC after: 3 days


# 518dd4c0 28-Sep-2011 Pawel Jakub Dawidek <pjd@FreeBSD.org>

After every activemap change flush disk's write cache, so that write
reordering won't make the actual write to be committed before marking
the coresponding extent as dirty.

It can be disabled in configuration file.

If BIO_FLUSH is not supported by the underlying file system we log a warning
and never send BIO_FLUSH again to that GEOM provider.

MFC after: 3 days


# 7f46e21d 27-Sep-2011 Pawel Jakub Dawidek <pjd@FreeBSD.org>

- Convert some impossible conditions into assertions.
- Add missing 'if' in comment.

MFC after: 3 days


# 571fdd7e 27-Sep-2011 Pawel Jakub Dawidek <pjd@FreeBSD.org>

Prefer PJDLOG_ASSERT() and PJDLOG_ABORT() over assert() and abort().
pjdlog versions will log problem to syslog when application is running in
background.

MFC after: 3 days


# 89bad89a 20-May-2011 Pawel Jakub Dawidek <pjd@FreeBSD.org>

If no listen address is specified, bind by default to:

tcp4://0.0.0.0:8457
tcp6://[::]:8457

MFC after: 3 weeks


# a87399ba 20-May-2011 Pawel Jakub Dawidek <pjd@FreeBSD.org>

Rename ipv4/ipv6 to tcp4/tcp6.

MFC after: 3 weeks


# d4cb6369 19-May-2011 Pawel Jakub Dawidek <pjd@FreeBSD.org>

In preparation for IPv6 support allow to specify multiple addresses to
listen on.

MFC after: 3 weeks


# b64a692b 08-May-2011 Pawel Jakub Dawidek <pjd@FreeBSD.org>

Allow to specify remote as 'none' again which was broken by r219351, where
'none' was defined as a value for checksum.

Reported by: trasz
MFC after: 1 week


# 0d9d733c 08-May-2011 Mikolaj Golub <trociny@FreeBSD.org>

Fix isitme(), which is used to check if node-specific configuration
belongs to our node, and was returning false positive if the first
part of a node name matches short hostname.

Approved by: pjd (mentor)


# 20f32a33 20-Apr-2011 Pawel Jakub Dawidek <pjd@FreeBSD.org>

Timeout must be positive.

MFC after: 1 week


# ac651867 12-Apr-2011 Pawel Jakub Dawidek <pjd@FreeBSD.org>

The replication mode that is currently support is fullsync, not memsync.
Correct this and print a warning if different replication mode is
configured.

MFC after: 1 week


# 0b626a28 21-Mar-2011 Pawel Jakub Dawidek <pjd@FreeBSD.org>

In hast.conf we define the other node's address in 'remote' variable.
This way we know how to connect to secondary node when we are primary.
The same variable is used by the secondary node - it only accepts
connections from the address stored in 'remote' variable.
In cluster configurations it is common that each node has its individual
IP address and there is one addtional shared IP address which is assigned
to primary node. It seems it is possible that if the shared IP address is
from the same network as the individual IP address it might be choosen by
the kernel as a source address for connection with the secondary node.
Such connection will be rejected by secondary, as it doesn't come from
primary node individual IP.

Add 'source' variable that allows to specify source IP address we want to
bind to before connecting to the secondary node.

MFC after: 1 week


# 8cd3d45a 06-Mar-2011 Pawel Jakub Dawidek <pjd@FreeBSD.org>

Allow to compress on-the-wire data using two algorithms:
- HOLE - it simply turns all-zero blocks into few bytes header;
it is extremely fast, so it is turned on by default;
it is mostly intended to speed up initial synchronization
where we expect many zeros;
- LZF - very fast algorithm by Marc Alexander Lehmann, which shows
very decent compression ratio and has BSD license.

MFC after: 2 weeks


# 1fee97b0 06-Mar-2011 Pawel Jakub Dawidek <pjd@FreeBSD.org>

Allow to checksum on-the-wire data using either CRC32 or SHA256.

MFC after: 2 weeks


# a7130d73 26-Dec-2010 Pawel Jakub Dawidek <pjd@FreeBSD.org>

Detect when resource is configured more than once.

MFC after: 3 days


# 66db33a1 26-Dec-2010 Pawel Jakub Dawidek <pjd@FreeBSD.org>

When node-specific configuration is missing in resource section, provide
more useful information. Instead of:

hastd: remote address not configured for resource foo

Print the following:

No resource foo configuration for this node (acceptable node names: freefall, freefall.freebsd.org, 44333332-4c44-4e31-4a30-313920202020).

MFC after: 3 days


# 584a9bc3 24-Oct-2010 Pawel Jakub Dawidek <pjd@FreeBSD.org>

Plug memory leaks.

Found with: valgrind
MFC after: 3 days


# a7d5f7eb 19-Oct-2010 Jamie Gritton <jamie@FreeBSD.org>

A new jail(8) with a configuration file, to replace the work currently done
by /etc/rc.d/jail.


# 0becad39 27-Aug-2010 Pawel Jakub Dawidek <pjd@FreeBSD.org>

Allow to execute specified program on various HAST events.

MFC after: 2 weeks
Obtained from: Wheel Systems Sp. z o.o. http://www.wheelsystems.com


# 3f828c18 27-Aug-2010 Pawel Jakub Dawidek <pjd@FreeBSD.org>

Reduce indent where possible.

MFC after: 2 weeks
Obtained from: Wheel Systems Sp. z o.o. http://www.wheelsystems.com


# bbbb114c 05-Aug-2010 Pawel Jakub Dawidek <pjd@FreeBSD.org>

Prepare configuration parsing code to be called multiple times:
- Don't exit on errors if not requested.
- Don't keep configuration in global variable, but allocate memory for
configuration.
- Call yyrestart() before yyparse() so that on error in configuration file
we will start from the begining next time and not from the place we left of.

MFC after: 1 month


# badd3232 01-May-2010 Pawel Jakub Dawidek <pjd@FreeBSD.org>

MFC r207070,r207343,r207345,r207347,r207348,r207371,r207372,r207390:

r207070:

Fix compilation with WITHOUT_CRYPT or WITHOUT_OPENSSL options.

Reported by: Andrei V. Lavreniyuk <andy.lavr@reactor-xg.kiev.ua>

r207343:

Don't assume that "resource" property is in metadata.

Reported by: Mikolaj Golub <to.my.trociny@gmail.com>

r207345:

Use WEXITSTATUS() to obtain real exit code.

r207347:

Mark temporary issues as such.

r207348:

Restart worker thread only if the problem was temporary.
In case of persistent problem we don't want to loop forever.

r207371:

Fix a problem where hastd will stuck in recv(2) after sending request to
secondary, which died between send(2) and recv(2). Do it by adding timeout
to recv(2) for primary incoming and outgoing sockets and secondary outgoing
socket.

Reported by: Mikolaj Golub <to.my.trociny@gmail.com>
Tested by: Mikolaj Golub <to.my.trociny@gmail.com>

r207372:

- Check if the worker process was killed by signal and restart it.
- Improve logging.

Pointed out by: Garrett Cooper <yanefbsd@gmail.com>

r207390:

Default connection timeout is way too long. To make it shorter we have to
make socket non-blocking, connect() and if we get EINPROGRESS, we have to
wait using select(). Very complex, but I know no other way to define
connection timeout for a given socket.

Reported by: hiroshi@soupacific.com


# 5571414c 29-Apr-2010 Pawel Jakub Dawidek <pjd@FreeBSD.org>

Fix a problem where hastd will stuck in recv(2) after sending request to
secondary, which died between send(2) and recv(2). Do it by adding timeout
to recv(2) for primary incoming and outgoing sockets and secondary outgoing
socket.

Reported by: Mikolaj Golub <to.my.trociny@gmail.com>
Tested by: Mikolaj Golub <to.my.trociny@gmail.com>
MFC after: 3 days


# 2b98f840 18-Apr-2010 Pawel Jakub Dawidek <pjd@FreeBSD.org>

MFC r204076,r204077,r204083,r205279:

r204076:

Please welcome HAST - Highly Avalable Storage.

HAST allows to transparently store data on two physically separated machines
connected over the TCP/IP network. HAST works in Primary-Secondary
(Master-Backup, Master-Slave) configuration, which means that only one of the
cluster nodes can be active at any given time. Only Primary node is able to
handle I/O requests to HAST-managed devices. Currently HAST is limited to two
cluster nodes in total.

HAST operates on block level - it provides disk-like devices in /dev/hast/
directory for use by file systems and/or applications. Working on block level
makes it transparent for file systems and applications. There in no difference
between using HAST-provided device and raw disk, partition, etc. All of them
are just regular GEOM providers in FreeBSD.

For more information please consult hastd(8), hastctl(8) and hast.conf(5)
manual pages, as well as http://wiki.FreeBSD.org/HAST.

Sponsored by: FreeBSD Foundation
Sponsored by: OMCnet Internet Service GmbH
Sponsored by: TransIP BV

r204077:

Remove some lines left over by accident.

r204083:

Add missing KEYWORD line.

Pointed out by: dougb

r205279 sys:

Simplify loops.


# fe0506d7 09-Mar-2010 Marcel Moolenaar <marcel@FreeBSD.org>

Create the altix project branch. The altix project will add support
for the SGI Altix 350 to FreeBSD/ia64. The hardware used for porting
is a two-module system, consisting of a base compute module and a
CPU expansion module. SGI's NUMAFlex architecture can be an excellent
platform to test CPU affinity and NUMA-aware features in FreeBSD.


# 32115b10 18-Feb-2010 Pawel Jakub Dawidek <pjd@FreeBSD.org>

Please welcome HAST - Highly Avalable Storage.

HAST allows to transparently store data on two physically separated machines
connected over the TCP/IP network. HAST works in Primary-Secondary
(Master-Backup, Master-Slave) configuration, which means that only one of the
cluster nodes can be active at any given time. Only Primary node is able to
handle I/O requests to HAST-managed devices. Currently HAST is limited to two
cluster nodes in total.

HAST operates on block level - it provides disk-like devices in /dev/hast/
directory for use by file systems and/or applications. Working on block level
makes it transparent for file systems and applications. There in no difference
between using HAST-provided device and raw disk, partition, etc. All of them
are just regular GEOM providers in FreeBSD.

For more information please consult hastd(8), hastctl(8) and hast.conf(5)
manual pages, as well as http://wiki.FreeBSD.org/HAST.

Sponsored by: FreeBSD Foundation
Sponsored by: OMCnet Internet Service GmbH
Sponsored by: TransIP BV