deleting old calendar entries

Discuss the Scalix web client

Moderators: ScalixSupport, admin

RickC
Posts: 194
Joined: Tue Nov 16, 2004 12:55 pm
Location: Massachusetts USA
Contact:

deleting old calendar entries

Postby RickC » Tue Aug 02, 2011 10:50 am

Hi,

Is there a way for a user to delete old entries? I have a user with 3 years worth they'd like to remove, and deleting individual entries is unrealistic.

Thanks, Rick

les
Scalix Star
Scalix Star
Posts: 819
Joined: Thu Feb 23, 2006 10:18 am
Location: Sydney, Australia

Re: deleting old calendar entries

Postby les » Wed Aug 03, 2011 10:11 am

Couple of ways....

1. connect via imap and sort calendar folder by date, select all and delete.

2. omtidyu can help you out. Check the man page for selecting the Calendar folder, i think its "-l"

an example....

omtidyu -d -T i -a 0 -B -u "John Smith" (Send all mail in Inbox, specified by -T, to Deleted Items)

***Next Command is point of no return....i.e. permanent delete***
omtidyu -d -k -T i -a 0 -B -u "John Smith" (Completely delete all mail in Inbox, specified by -T)
***WARNING: Subfolders will also be cleaned***
-B no password required
-d send to deleted items
-k delete from deleted items
-a age in days
-u user
-T folder to work on.
i refers to the intray;
o refers to the outtray;
f refers to the filing cabinet;
w refers to the wastebasket (Deleted Items folder).
p refers to the pending tray; and
l refers to the List Area.
r refers to the Scalix Recovered Items folder.
Regards,

Les Stott

RickC
Posts: 194
Joined: Tue Nov 16, 2004 12:55 pm
Location: Massachusetts USA
Contact:

Re: deleting old calendar entries

Postby RickC » Wed Aug 03, 2011 10:15 am

Thanks Les -

I'm assuming its not easy for a user to do this via SWA?

Thanks for the tip with omtidyu - I wasn't sure what the calendar would be.

Rick

RickC
Posts: 194
Joined: Tue Nov 16, 2004 12:55 pm
Location: Massachusetts USA
Contact:

Re: deleting old calendar entries

Postby RickC » Wed Aug 03, 2011 10:22 am

can someone confirm what the calendar is in omtidyu?

omtidyu -B -u "richard chamberlain" -T l -a 3 -R
Deletable items for 'Richard D. Chamberlain /mt/CN=Richard D Chamberlain'

__________________________________________________________________
CRITERIA : Messages in the List Area older than 3 days.

^^^^^^^^^^^^^^SUBJECT^^^^^^^^^^^^^^^ ^SIZE^ ^^AGE^^ ^^SENDER^^

and I have an extensive calendar with entries going back a few years.

Thanks,
Rick

les
Scalix Star
Scalix Star
Posts: 819
Joined: Thu Feb 23, 2006 10:18 am
Location: Sydney, Australia

Re: deleting old calendar entries

Postby les » Wed Aug 03, 2011 10:31 am

RickC wrote:can someone confirm what the calendar is in omtidyu?

omtidyu -B -u "richard chamberlain" -T l -a 3 -R
Deletable items for 'Richard D. Chamberlain /mt/CN=Richard D Chamberlain'

__________________________________________________________________
CRITERIA : Messages in the List Area older than 3 days.

^^^^^^^^^^^^^^SUBJECT^^^^^^^^^^^^^^^ ^SIZE^ ^^AGE^^ ^^SENDER^^

and I have an extensive calendar with entries going back a few years.

Thanks,
Rick


Rick,

Correct syntax....(sorry i was a bit off target with the switches)

-f = filing cabinet
-l = search only the folder named Calendar

omtidyu -B -u "richard chamberlain" -T f -l Calendar -a 3 -R
Regards,

Les Stott

RickC
Posts: 194
Joined: Tue Nov 16, 2004 12:55 pm
Location: Massachusetts USA
Contact:

Re: deleting old calendar entries

Postby RickC » Wed Aug 03, 2011 10:33 am

Awesome, thanks!

florian
Scalix
Scalix
Posts: 3852
Joined: Fri Dec 24, 2004 8:16 am
Location: Frankfurt, Germany
Contact:

Re: deleting old calendar entries

Postby florian » Wed Aug 03, 2011 3:54 pm

I don't think this will do what you expect or want - the date the delete will be based on will be the age of the folder entry that represents the calendar item, i.e. the reference date will be the creation or last change of the element, and will have NOTHING to do with the event date. this means that some really old recurring object may get marked up for deletion, while some other object that has been touched won't.

I think there is an enhancement open against omtidyu to do what is desired here, but it is not implemented yet and there is currently no target release for such an enhancement.

i think the only way to do this programmatically will involve some heavy scripting or programming, and retrieving the objects via IMAP as ICAL or via CalDAV is probably the way to go. Find those eligible for deletion, though, won't be easy, as it will involve parsing of complex recurrency rules for those appointments.

Cheers,
Florian
Florian von Kurnatowski, Die Harder!

RickC
Posts: 194
Joined: Tue Nov 16, 2004 12:55 pm
Location: Massachusetts USA
Contact:

Re: deleting old calendar entries

Postby RickC » Thu Aug 04, 2011 7:00 am

Thanks for the info, Florian!

Is there a simple way for a user in SWA to do this? or even in outlook?

Rick

florian
Scalix
Scalix
Posts: 3852
Joined: Fri Dec 24, 2004 8:16 am
Location: Frankfurt, Germany
Contact:

Re: deleting old calendar entries

Postby florian » Thu Aug 04, 2011 10:13 am

SWA for sure not, Outlook not that I would know of, although I could think that Outlook's archiving feature may have a filter that looks at the actual calendar items dates, not the creation date. I'm not an outlook expert, though....

Florian.
Florian von Kurnatowski, Die Harder!

RickC
Posts: 194
Joined: Tue Nov 16, 2004 12:55 pm
Location: Massachusetts USA
Contact:

Re: deleting old calendar entries

Postby RickC » Wed Aug 10, 2011 11:55 am

Just curious, is there a way to determine how many users are 'extensively' using the calendar, and what type of maintenance on these are the norm? does anyone ever clean up old calendar entries?

florian
Scalix
Scalix
Posts: 3852
Joined: Fri Dec 24, 2004 8:16 am
Location: Frankfurt, Germany
Contact:

Re: deleting old calendar entries

Postby florian » Wed Aug 10, 2011 2:27 pm

omtidyu (in reporting mode, with age=0, don't add delete switches) reports on the #items in a particular folder. For the calendar folder, I'd think that a folder of up to 2000 items or so should work well. Calendards >10000 items generally suck at performance and, when kinda calulating how many appointments per day this means over a large number of days, doesn't realistically make sense. (keep in mind that recurring appointments count as ONE item as the recurrency is stored as a pattern INSIDE the item).

Florian.
Florian von Kurnatowski, Die Harder!

RickC
Posts: 194
Joined: Tue Nov 16, 2004 12:55 pm
Location: Massachusetts USA
Contact:

Re: deleting old calendar entries

Postby RickC » Wed Aug 10, 2011 2:56 pm

Hi Florian,

Thanks for the quick reply.

Is there an option in omtidyallu that will show me the number of users with, say, more than 20 recent items in their calendar?

# omtidyallu -T f -l Calendar -a 0 -R | wc -l - only counts the calendar items, without telling me the users. If I take the wc -l out, I'll get a report on 2800 users, which is pretty extensive considering we've been using Scalix for ... I think 8 years now.

Thanks,
Rick

florian
Scalix
Scalix
Posts: 3852
Joined: Fri Dec 24, 2004 8:16 am
Location: Frankfurt, Germany
Contact:

Re: deleting old calendar entries

Postby florian » Fri Aug 12, 2011 5:55 am

Hi Rick,

there is no direct command for that, but, as a first step, I'd recommend leaving off the "-R" bit, because this will only give you summaries per-user with the number of items, and no listing of the actual items, so it's much simpler.

It's still a multi-line format, however, so to parse this I believe you'll probably have to do some AWK and GREP magic. I'll leave this as an exercise to the readers for the moment (:-( don't really have the time to work out the script right now...)

-- F.
Florian von Kurnatowski, Die Harder!


Return to “Scalix Web Access”



Who is online

Users browsing this forum: No registered users and 9 guests

cron