# Parsing error and DRBD versions

**URL:** https://forums.linbit.com/t/parsing-error-and-drbd-versions/707
**Category:** DRBD
**Tags:** drbd
**Created:** [March 28, 2025, 6:21pm UTC](https://forums.linbit.com/t/parsing-error-and-drbd-versions/707 "2025-03-28T18:21:37Z")
**Posts on this page:** 10
**Page:** 1

<div class="post-metadata">

### Author: ![paulororke](https://avatars.discourse-cdn.com/v4/letter/p/d07c76/32.png) [@paulororke](https://forums.linbit.com/u/paulororke)
#### Post date: [March 28, 2025, 6:21pm UTC](https://forums.linbit.com/t/parsing-error-and-drbd-versions/707/1 "2025-03-28T18:21:37Z")

</div>

Why would I get a parse error on this config on a host running DRBDADM 9.31.0 but not on 9.28.0?

```auto
resource nchub {
  device /dev/drbd19;
  disk /dev/vg0/nchub;
  meta-disk internal;
  on trk-kvm-02 {
    node-id 2;
  }
  on trk-kvm-04 {
    node-id 4;
  }
  connection {
    host trk-kvm-02 address 10.10.2.186:7286;
    host trk-kvm-04 address 10.10.2.187:7287;
  }
}

```

on trk-kvm-02 it parses fine and I can create the resource:

```auto
$ sudo drbdadm status nchub
nchub role:Secondary
  disk:Inconsistent
  trk-kvm-04 connection:Connecting

```

using 9.28.0

```auto
@trk-kvm-02: $ sudo drbdadm --version
DRBDADM_BUILDTAG=GIT-hash:\ ba2ce9037989b6141222c7901d1219cf852949f1\ build\ by\ buildd@lcy02-amd64-074\,\ 2024-05-06\ 09:10:36
DRBDADM_API_VERSION=2
DRBD_KERNEL_VERSION_CODE=0x090209
DRBD_KERNEL_VERSION=9.2.9
DRBDADM_VERSION_CODE=0x091c00
DRBDADM_VERSION=9.28.0

```

but the exact same file on trk-kvm-04 with 9.31.0-rc.1 fails with:

```auto
$ sudo drbdadm create-md nchub
drbd.d/nchub.res:6: Parse error: 'disk | device | address | meta-disk | flexible-meta-disk' expected,
        but got 'node-id'

```

the only difference I can see is the version of DRBD:

```auto
@trk-kvm-04:~$ sudo drbdadm --version
DRBDADM_BUILDTAG=GIT-hash:\ 2411ff2e4241716463b4afa8530dc3c628c157ce\ build\ by\ buildd@lcy02-amd64-089\,\ 2025-03-24\ 09:51:42
DRBDADM_API_VERSION=1
DRBD_KERNEL_VERSION_CODE=0x000000
DRBDADM_VERSION_CODE=0x091f00
DRBDADM_VERSION=9.31.0-rc.1

```

I was expecting both versions to accept the same syntax.

What am I missing?

---

<div class="post-metadata">

### Author: ![michael](https://yyz1.discourse-cdn.com/flex003/user_avatar/forums.linbit.com/michael/32/16_2.png) [@michael](https://forums.linbit.com/u/michael)
#### Post date: [March 31, 2025, 7:48pm UTC](https://forums.linbit.com/t/parsing-error-and-drbd-versions/707/2 "2025-03-31T19:48:00Z")

</div>

Can you verify that the DRBD 9 kernel module is actually loaded (`cat /proc/drbd`)?

`drbd-utils` checks which version of the kmod is loaded into the kernel and then uses the DRBD 8 or DRBD 9 parser accordingly. `node-id` is a DRBD 9 option but not available in DRBD 8.

---

<div class="post-metadata">

### Author: ![paulororke](https://avatars.discourse-cdn.com/v4/letter/p/d07c76/32.png) [@paulororke](https://forums.linbit.com/u/paulororke)
#### Post date: [March 31, 2025, 8:28pm UTC](https://forums.linbit.com/t/parsing-error-and-drbd-versions/707/3 "2025-03-31T20:28:03Z")

</div>

Thanks for this,

Nothing is loaded at all it seems.

This is a new host and my first resource to add. I can’t get past create-md:

```auto
@trk-kvm-04:/etc/drbd.d$ sudo drbdadm create-md nchub.res
drbd.d/nchub.res:6: Parse error: 'disk | device | address | meta-disk | flexible-meta-disk' expected,
        but got 'node-id'
@trk-kvm-04:/etc/drbd.d$ sudo cat /etc/drbd
cat: /etc/drbd: No such file or directory

```

Actually - it is not accurate to say a new host, it was used in the past and may have DRBD8 on there. How can I force it to use DRBD 9? I expected to see only DRBD9 after issuing:

`add-apt-repository ppa:linbit/linbit-drbd9-stack`

then updating. It did install DRBD 9, I even rebooted the host expecting to have DRBD9 across the board.

What am I missing?

---

<div class="post-metadata">

### Author: ![michael](https://yyz1.discourse-cdn.com/flex003/user_avatar/forums.linbit.com/michael/32/16_2.png) [@michael](https://forums.linbit.com/u/michael)
#### Post date: [March 31, 2025, 9:31pm UTC](https://forums.linbit.com/t/parsing-error-and-drbd-versions/707/4 "2025-03-31T21:31:40Z")

</div>

I noticed that you are using a PPA and a release candidate (`rc`) version of `drbdadm`. I will speculate that there are broken dependencies that weren’t met with the upgrade/install and so your node fell back on the DRBD kmod in the mainline kernel (DRBD 8.4). I will check in with the development team about this.

[edited post to remove some wrong advice.]

---

<div class="post-metadata">

### Author: ![rck](https://avatars.discourse-cdn.com/v4/letter/r/c37758/32.png) [@rck](https://forums.linbit.com/u/rck)
#### Post date: [April 1, 2025, 7:09am UTC](https://forums.linbit.com/t/parsing-error-and-drbd-versions/707/5 "2025-04-01T07:09:03Z")

</div>

This looks more like a kernel module issue than a `drbd-utils` issue. Can you please provide the output of `uname -a` and `cat /etc/os-release`?

---

<div class="post-metadata">

### Author: ![paulororke](https://avatars.discourse-cdn.com/v4/letter/p/d07c76/32.png) [@paulororke](https://forums.linbit.com/u/paulororke)
#### Post date: [April 1, 2025, 2:23pm UTC](https://forums.linbit.com/t/parsing-error-and-drbd-versions/707/6 "2025-04-01T14:23:32Z")

</div>

Thanks for looking into this guys.

```auto
@trk-kvm-04:~$ uname -a
Linux trk-kvm-04 5.15.0-135-generic #146-Ubuntu SMP Sat Feb 15 17:06:22 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux

@trk-kvm-04:~$ cat /etc/os-release
PRETTY_NAME="Ubuntu 22.04.5 LTS"
NAME="Ubuntu"
VERSION_ID="22.04"
VERSION="22.04.5 LTS (Jammy Jellyfish)"
VERSION_CODENAME=jammy
ID=ubuntu
ID_LIKE=debian
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
UBUNTU_CODENAME=jammy

```

What specifically are yo looking for in there?

Please and thanks

Paul

---

<div class="post-metadata">

### Author: ![rck](https://avatars.discourse-cdn.com/v4/letter/r/c37758/32.png) [@rck](https://forums.linbit.com/u/rck)
#### Post date: [April 2, 2025, 7:54am UTC](https://forums.linbit.com/t/parsing-error-and-drbd-versions/707/7 "2025-04-02T07:54:56Z")

</div>

I have a slightly different kernel (just 1 minor newer), which should not matter, and everything works as expected. I installed the kernel module via dkms from the PPA (`apt install drbd-dkms`):

```auto
root@ubuntu-jammy-23:~# drbdadm --version
DRBDADM_BUILDTAG=GIT-hash:\ 2411ff2e4241716463b4afa8530dc3c628c157ce\ build\ by\ buildd@lcy02-amd64-089\,\ 2025-03-24\ 09:51:42
DRBDADM_API_VERSION=2
DRBD_KERNEL_VERSION_CODE=0x09020d
DRBD_KERNEL_VERSION=9.2.13
DRBDADM_VERSION_CODE=0x091f00
DRBDADM_VERSION=9.31.0-rc.1
root@ubuntu-jammy-23:~# uname -a
Linux ubuntu-jammy-23 5.15.0-136-generic #147-Ubuntu SMP Sat Mar 15 15:53:30 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux

```

From what I see you don’t have a valid DRBD9 kernel module for the kernel you are running.

What I would do:  
`apt install --reinstall drbd-dkms` and look for any errors. If everything looks fine, then a `modinfo -F version drbd`. If that shows a version 9, then `rmmod drbd` (just to make sure a loaded 8.4 is unloaded), `modprobe drbd`, `cat /proc/drbd` to see if the version 9 module really is loaded.

tl;tr: not an utils issue at all, for whatever reason you don’t have a valid DRBD9 kmod for your kernel (headers missing?).

---

<div class="post-metadata">

### Author: ![paulororke](https://avatars.discourse-cdn.com/v4/letter/p/d07c76/32.png) [@paulororke](https://forums.linbit.com/u/paulororke)
#### Post date: [April 2, 2025, 3:53pm UTC](https://forums.linbit.com/t/parsing-error-and-drbd-versions/707/8 "2025-04-02T15:53:43Z")

</div>

Brilliant!

You nailed it and I am back up and syncing!

The reinstall went perfectly, DRBD9 installed and kernel module manually loaded.

I very much appreciate the guidance.

---

<div class="post-metadata">

### Author: ![John\_Smith](https://avatars.discourse-cdn.com/v4/letter/j/d78d45/32.png) [@John\_Smith](https://forums.linbit.com/u/John_Smith)
#### Post date: [April 19, 2025, 2:33am UTC](https://forums.linbit.com/t/parsing-error-and-drbd-versions/707/9 "2025-04-19T02:33:25Z")

</div>

How to install drbd on Redhat or Ubuntu and then start it automatically at boot  
All commands below are executed with root privileges.

]# echo drbd \> /etc/modules-load.d/drbd.conf

Usually, when loading manually, as mentioned above  
]# modprobe drbd

How to check if the driver is loaded  
]# modinfo drbd

Checking if it is loaded at the kernel level  
]# lsmod | grep -i drbd  
drbd 568697 0  
libcrc32c 12644 2 drbd

That’s it.

---

<div class="post-metadata">

### Author: ![paulororke](https://avatars.discourse-cdn.com/v4/letter/p/d07c76/32.png) [@paulororke](https://forums.linbit.com/u/paulororke)
#### Post date: [March 17, 2026, 7:03pm UTC](https://forums.linbit.com/t/parsing-error-and-drbd-versions/707/10 "2026-03-17T19:03:55Z")

</div>

I just do this:

```auto
cat /etc/systemd/system/drbd.service
[Unit]
Description=DRBD Startup Service
After=network.target

[Service]
Type=oneshot
RemainAfterExit=yes
ExecStart=/sbin/drbdadm up all

[Install]
WantedBy=multi-user.target

```

works for me. Or is that not a question?
