André,

Never mind.  I figured it out.

For future reference, I used this command:

sudo psql -h /var/run/caldavd/PostgresSocket -U caldav caldav -c "select * from calendar_object where icalendar_uid = 'EB386194-F40A-41E3-8FB1-FD8163520FCD';"

to dump the entire event record, and found in the 1st column the resource_id I needed. Then I used the command you suggested:

sudo /Applications/Server.app/Contents/ServerRoot/Library/CalendarServer/bin/calendarserver_verify_data --fix --nuke 17923

to remove the problematic event.

Thanks again for your patience assistance.

Ian


On Aug 18, 2017, at 1:23 PM, Ian Baker <ibaker@eem.ca> wrote:

Thanks André for the response.

We're not running the current Server.app v5.3.1 - only the older version v5.2. Unfortunately, we can't upgrade at the current time.

With Server.app v5.2, it seems that calendarserver_verify_data is also an older version that doesn't yet support UID references.

 ./calendarserver_verify_data --nuke UID:EB386194-F40A-41E3-8FB1-FD8163520FCD

---- CalVerify Nuke Service version: 12 ----

---- Removing calendar resource ----
nuke argument must be a calendar object path or an SQL resource-id

Can I download and run the current version of calendarserver_verify_data (that supports UID reverences) against an older version of the calendar server data?

If not, how can I translate a UID reference into either a SQL RID or a PATH reference?

Thanks

Ian

On Aug 14, 2017, at 3:45 PM, Andre LaBranche <dre@apple.com> wrote:

Hi,

Sorry for the slow reply.

On Aug 10, 2017, at 1:52 PM, Ian Baker <ibaker@eem.ca> wrote:

The boss is running macOS 10.12.6 against Server.app 5.2 on macOS 10.11.6

The boss tries to remove a repeating event, but gets this error "The server responded: "403" to operation CalDAVWriteEntityQueueableOperation

The event had two participants, the boss and another, however the event no longer appears on the other user's calendar. I don't know who was the originator of the event.

Is there any way to force the removal of this event from the boss's calendar?

You could try:

sudo /Applications/Server.app/Contents/ServerRoot/Library/CalendarServer/bin/calendarserver_verify_data --nuke <reference to the event>

This tool has many other options (run with -h to see them), but 'nuke' is not related to (and cannot be used concurrently with) any of them. The reference to the event can be in one of three forms: PATH, UID or RID. From the usage help:

PATH is the full /calendars/__uids__/XXX/YYY/ZZZ.ics object resource path. UID is the iCalendar UID, prefixed with "uid:", of the resources to remove. RID is the SQL DB resource id.


The UID can be found by looking inside the event. For example, using Calendar on macOS, drag the event to the desktop, then open it with a text editor and look for the "UID" property. Alternatively, use grep against the file you downloaded:

# print lines containing UID inside VEVENT blocks, but excluding VALARM blocks
╭─ andre@zomg ~/Desktop
╰─ $ awk '/BEGIN:VEVENT/ {f=1}; /BEGIN:VALARM/ {f=0}; /UID/ && f; /END:VALARM/ {f=1}; /END:VEVENT/{f=0}' test.ics
UID:09F6D2C8-0551-4656-9789-7DDF9173A323
UID:09F6D2C8-0551-4656-9789-7DDF9173A323
UID:09F6D2C8-0551-4656-9789-7DDF9173A323

If the event is recurring, the UID may appear multiple times.

RID is a database-specific token; easier to use either PATH or UID.

-dre



Thanks

Ian
_______________________________________________
calendarserver-users mailing list
calendarserver-users@lists.macosforge.org
https://lists.macosforge.org/mailman/listinfo/calendarserver-users