subscriptions.conf log spam

Don Badrak dbadrak at tco.census.gov
Tue Sep 16 10:09:28 PDT 2008


> Don Badrak wrote:

> Right now the only tool that can cancel a subscription is the ipptest
> program in the test directory of the CUPS sources - you'll need to
> create a test file to cancel the numbered subscription:
>
>      {
>      OPERATION cancel-subscription
>      GROUP operation
>      ATTR charset attributes-charset utf-8
>      ATTR language attributes-natural-language en
>      ATTR uri printer-uri $uri
>      ATTR name requesting-user-name $user
>      ATTR integer notify-subscription-id SUBSCRIPTION_NUMBER
>      STATUS successful-ok
>      }

I tried this:

{
     OPERATION cancel-subscription
     GROUP operation
     ATTR charset attributes-charset utf-8
     ATTR language attributes-natural-language en
     ATTR uri printer-uri $uri
     ATTR name requesting-user-name $user
     ATTR integer notify-subscription-id 1
     STATUS successful-ok
}

# ./ipptest -v ipp://xx.xx.xx.xx s.cancel.1
"s.cancel.1":
Cancel-Subscription:
        attributes-charset (charset) = "utf-8"
        attributes-natural-language (language) = "en"
        printer-uri (uri) = "ipp://xx.xx.xx.xx"
        requesting-user-name (name) = "root"
        notify-subscription-id (integer) = 1
    s.cancel                                                     [FAIL]
        RECEIVED: 124 bytes in response
        BAD STATUS
        status-code = 0406 (notify-subscription-id 1 no good!)
        attributes-charset (charset) = "utf-8"
        attributes-natural-language (language) = "en"
        status-message (text) = "notify-subscription-id 1 no good!"

It's odd.  Before trying this, I stopped cupsd, edited the subscriptions.conf and changed it to this:

<Subscription 2>
Events printer-stopped server-restarted server-started server-stopped
Owner myuser
Recipient mailto:dbadrak at tco.census.gov
LeaseDuration 0
Interval 0
ExpirationTime 0
</Subscription>

After restarting I was still getting printer state changes from idle to processing (and back to idle).   I used to have in the Events:

Events printer-state-change printer-stopped

It is like it has "remembered" my subscription #1.

BTW, this is CUPS 1.2.4 (part of RHEL5.2).

Don




More information about the cups mailing list