Results 1 to 9 of 9

Thread: edit saved searches via command line

  1. #1
    rkerr is offline Active Member
    Join Date
    Jan 2007
    Posts
    42
    Rep Power
    8

    Default edit saved searches via command line

    Hi All.

    A user had bad syntax on a saved search that filtered his Inbox. problem is the web client crashes on load and we can't get at anyhting in his account.

    How can I remove his saved search via the command line? What tools exist to manipulate a users' saved searches?

    Thanks.

  2. #2
    rkerr is offline Active Member
    Join Date
    Jan 2007
    Posts
    42
    Rep Power
    8

    Default

    I have looked at all of the approriate documented command lines in zmprov and zmmailbox. None can find this problem:

    When the user logs in he gets the message:

    Unable to Parse Search Query

    Error text

    msg - Couldn't parse query: (is :unread) -tag:\Deleted
    code - mail.QUERY_PARSE_ERROR
    method - ZmCsfeCommand.prototype.invoke
    detail - soap:Sender
    data - [object Object]

    com.zimbra.cs.mailbox.MailServiceException: Couldn't parse query: (is :unread) -tag:\Deleted
    at com.zimbra.cs.mailbox.MailServiceException.QUERY_P ARSE_ERROR(MailServiceException.java:314)
    at com.zimbra.cs.operation.SearchOperation.callback(S earchOperation.java:83)
    at com.zimbra.cs.operation.Operation.schedule(Operati on.java:180)
    at com.zimbra.cs.service.mail.Search.handle(Search.ja va:69)
    at com.zimbra.soap.SoapEngine.dispatchRequest(SoapEng ine.java:266)
    at com.zimbra.soap.SoapEngine.dispatch(SoapEngine.jav a:163)
    at com.zimbra.soap.SoapEngine.dispatch(SoapEngine.jav a:85)
    at com.zimbra.soap.SoapServlet.doPost(SoapServlet.jav a:220)
    at javax.servlet.http.HttpServlet.service(HttpServlet .java:709)
    at com.zimbra.cs.servlet.ZimbraServlet.service(Zimbra Servlet.java:152)
    at javax.servlet.http.HttpServlet.service(HttpServlet .java:802)
    at org.apache.catalina.core.ApplicationFilterChain.in ternalDoFilter(ApplicationFilterChain.java:252)
    at org.apache.catalina.core.ApplicationFilterChain.do Filter(ApplicationFilterChain.java:173)
    at org.apache.catalina.core.StandardWrapperValve.invo ke(StandardWrapperValve.java:213)
    at org.apache.catalina.core.StandardContextValve.invo ke(StandardContextValve.java:178)
    at org.apache.catalina.core.StandardHostValve.invoke( StandardHostValve.java:126)
    at org.apache.catalina.valves.ErrorReportValve.invoke (ErrorReportValve.java:105)
    at org.apache.catalina.core.StandardEngineValve.invok e(StandardEngineValve.java:107)
    at org.apache.catalina.valves.AccessLogValve.invoke(A ccessLogValve.java:541)
    at org.apache.catalina.connector.CoyoteAdapter.servic e(CoyoteAdapter.java:148)
    at org.apache.coyote.http11.Http11Processor.process(H ttp11Processor.java:869)
    at org.apache.coyote.http11.Http11BaseProtocol$Http11 ConnectionHandler.processConnection(Http11BaseProt ocol.java:667)
    at org.apache.tomcat.util.net.PoolTcpEndpoint.process Socket(PoolTcpEndpoint.java:527)
    at org.apache.tomcat.util.net.LeaderFollowerWorkerThr ead.runIt(LeaderFollowerWorkerThread.java:80)
    at org.apache.tomcat.util.threads.ThreadPool$ControlR unnable.run(ThreadPool.java:684)
    at java.lang.Thread.run(Thread.java:619)
    Caused by: com.zimbra.cs.index.queryparser.ParseException: Lexical error at line 1, column 5. Encountered: ":" (58), after : ""
    at com.zimbra.cs.index.queryparser.ZimbraQueryParser. Parse(ZimbraQueryParser.java:248)
    at com.zimbra.cs.index.ZimbraQuery.<init>(ZimbraQuery .java:2004)
    at com.zimbra.cs.mailbox.Mailbox.search(Mailbox.java: 2766)
    at com.zimbra.cs.operation.SearchOperation.callback(S earchOperation.java:75)
    ... 24 more

  3. #3
    rkerr is offline Active Member
    Join Date
    Jan 2007
    Posts
    42
    Rep Power
    8

    Default

    The interface crashes on this before any of the folders are visible: The user cannot change anything


  4. #4
    phoenix is online now Zimbra Consultant & Moderator
    Join Date
    Sep 2005
    Location
    Vannes, France
    Posts
    23,486
    Rep Power
    56

    Default

    You don't say which version/release of Zimbra you're using but here's a couple of thing to try. First do a 'zmprov ga user@domain.com' and have a look at the Sieve fields, make a copy of the data in there. Next look for the field

    Code:
    zimbraPrefMailInitialSearch
    and it should read as follows:

    Code:
    zimbraPrefMailInitialSearch: in:inbox or is:unread
    It's not quite clear which filter you're actually talking about but the Initial Search String is the first one to look at, if that's not set to the default or has an invalid entry then a user login can crash. Reset the field to "in:inbox or is:unread" and try a login to see if that's the problem. If it's the Sieve fields then I'd suggest you save a copy of the filters and reset them to a single valid filter with the following command:

    Code:
    zmprov modifyAccount user@domain.com zimbraMailSieveScript 'require ["fileinto", "reject", "tag", "flag"]
    If that works you can add the original filters (less the problem one) again later.
    Regards


    Bill


    Acompli: A new adventure for Co-Founder KevinH.

  5. #5
    rkerr is offline Active Member
    Join Date
    Jan 2007
    Posts
    42
    Rep Power
    8

    Default

    Perfect solution.

    I've been looking for Documentation on all of the account attributes. Does it exist somewhere?

  6. #6
    phoenix is online now Zimbra Consultant & Moderator
    Join Date
    Sep 2005
    Location
    Vannes, France
    Posts
    23,486
    Rep Power
    56

    Default

    Quote Originally Posted by rkerr View Post
    Perfect solution.
    Which one was it, the default search?

    Quote Originally Posted by rkerr View Post
    I've been looking for Documentation on all of the account attributes. Does it exist somewhere?
    There's a list of attributes on the wiki.
    Regards


    Bill


    Acompli: A new adventure for Co-Founder KevinH.

  7. #7
    rkerr is offline Active Member
    Join Date
    Jan 2007
    Posts
    42
    Rep Power
    8

    Default

    Just the initial Search. For some reason I didn't clue in when looking at the account page.

    The list of Attributes is great. Thanks much. Any word on when the actual meaning of those attributes will be documented? Or do I need to dig in to the code to get a better understanding?

    Seems like the interface should check to see that the query be valid before accepting a new initial search value. bug?? User entered is: unread. the space is obviously invalid.

    Thanks again for your help.

  8. #8
    phoenix is online now Zimbra Consultant & Moderator
    Join Date
    Sep 2005
    Location
    Vannes, France
    Posts
    23,486
    Rep Power
    56

    Default

    For the attributes I think the documentation in the source code would be the best at the moment.

    Which version of Zimbra are you on? The inability to login after the initial search was was made invalid was a bug, offhand I think that's been fixed in release 5 to still allow a login.
    Regards


    Bill


    Acompli: A new adventure for Co-Founder KevinH.

  9. #9
    rkerr is offline Active Member
    Join Date
    Jan 2007
    Posts
    42
    Rep Power
    8

    Default

    We are on 4.5.9. Eagerly awaiting GA on 5.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Editing Saved Searches
    By toddgeist in forum Users
    Replies: 4
    Last Post: 08-24-2010, 08:49 AM
  2. Adding saved searches to an entire domain?
    By SpecialKdkj in forum Administrators
    Replies: 2
    Last Post: 11-02-2007, 05:00 PM
  3. Cannot Edit Events in a Shared Calendar
    By Chewie71 in forum Administrators
    Replies: 0
    Last Post: 09-17-2007, 10:09 AM
  4. Replies: 2
    Last Post: 10-10-2006, 10:24 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •