...
Info |
---|
Paths and file names below assume a default installation location (/opt/shibboleth-idp) and unchanged logging/logback configuration. Though you might prefer to adjust your logging config and or make /opt/shibboleth-idp/logs a symbolic link to another file system/volumedirectory. You might also want to remove the "idp-" prefix from all the {process,warn,audit,consent-audit} log files since they'll likely end up in one IDP-specific logging directory anyway (and having all files start with the same letter isn't overly useful). But again, the examples below can't match local deployment decisions and so have been written to match a default IDP installation's behaviour. So please adjust as needed. |
Who and how am I
...
Code Block |
---|
language | bash |
---|
title | What IDP version is currently installed |
---|
|
$ /opt/shibboleth-idp/bin/version.sh
3.4.6 |
...
Code Block |
---|
language | bash |
---|
title | What does the IDP think of its own state? |
---|
|
/opt/shibboleth-idp/bin/status.sh |
Applying updates
See IDP 3 Updates for detailed instructions.
What's happening right now
...
Code Block |
---|
language | bash |
---|
title | Watch IDP und Webserver logs |
---|
|
multitail -f /opt/shibboleth-idp/logs/idp-process.log /var/log/tomcat8tomcat9/access.log |
Code Block |
---|
language | bash |
---|
title | Search for IDP Warnings and Errors |
---|
|
egrep 'WARN|ERROR' /opt/shibboleth-idp/logs/idp-process.log |
...
Code Block |
---|
language | bash |
---|
title | Tomcat STDOUT/STDERR (formerly catalina.out) |
---|
|
journalctl -u tomcat8tomcat9.service -e -f |
Code Block |
---|
language | bash |
---|
title | Trail all Tail relevant logs at once |
---|
|
multitail -f /opt/shibboleth-idp/logs/idp-process.log /var/log/tomcat8tomcat9/access.log -l 'journalctl -u tomcat8tomcat9.service -f' |
Who logged in and where, with what attributes sent
...
Code Block |
---|
language | bash |
---|
title | Audit log |
---|
|
multitail -f /opt/shibboleth-idp/logs/idp-audit.log |
...
Code Block |
---|
language | bash |
---|
title | What attributes and NameIDs would be going out for person X to service Y? |
---|
|
/opt/shibboleth-idp/bin/aacli.sh --saml2 -n someuser99 -r https://test-sp.aco.net/shibboleth |
Code Block |
---|
language | bash |
---|
title | Failed logins in Jan 2019 |
---|
|
zgrep ' failed$' /opt/shibboleth-idp/logs/idp-process.log.201901* |
...
Code Block |
---|
language | bash |
---|
title | HTTP User-Agent IP address in audit and access log |
---|
|
fgrep 192.168.1.99 /opt/shibboleth-idp/logs/idp-audit.log /var/log/tomcat8tomcat9/access.log |
What data will go out for userid X to service Y
The aacli is a very useful tool to test what data the running IDP would send for a given subject (replace SOME_USERID
below with the login name the subject would enter during authentication) to a given SP. Not only does that help verifying your attribute resolver and attribute filter configuration when you're making changes to either (or both), it can also be useful in debugging access problems someone experiences at a given SP as you can easily compare what data would go out for different subjects (e.g. in cases where access works for one person but fails for another) without needing the subjects' cooperation in this issue (or access to their password).
Code Block |
---|
language | bash |
---|
title | Attributes (and NameID) that would be sent |
---|
|
/opt/shibboleth-idp/bin/aacli.sh --saml2 -n SOME_USERID -r https://test-sp.aco.net/shibboleth
|
Statistics
ACOnet has contributed a log analysis tool for parsing the Shibboleth IDP's audit logs. For the current day use /opt/shibboleth-idp/logs/idp-audit.log
.
...
Code Block |
---|
language | bash |
---|
title | Can be done for whole months or even years |
---|
|
loganalysis.py -cul /opt/shibboleth-idp/logs/idp-audit.log.201812*
21 unique relying parties
15 unique userids
406 logins |
Maybe try one of the structured output formats for easy post-processing, e.g. JSON:
Code Block |
---|
language | js |
---|
title | Can be done for whole months or even years |
---|
|
$ loganalysis.py -j /opt/shibboleth-idp/logs/idp-audit.log.20200[1-6]*
{
"stats": {
"logins": 8327,
"rps": 211,
"users": 150
},
"logins_per_rp": {
"https://sp.example.org/saml": 29,
"https://wiki.example.edu/shibboleth": 163,
"usw.": "usf."
}
}
|
For more see the built-in help ( loganalysis.py --help
) or the examples in the documentation.
Debugging
Code Block |
---|
language | bash |
---|
title | Log SAML Messages on DEBUG |
---|
|
$EDITOR /opt/shibboleth-idp/conf/logback.xml # Set <logger name="PROTOCOL_MESSAGE" level="DEBUG"/> and save
/opt/shibboleth-idp/bin/reload-service.sh -id shibboleth.LoggingService |
Make sure to undo this after you're done to avoid filling up file systems/volumes/disks with unnecessary DEBUG messages.
See our IDP 3 Metadata configuration documentation.