$ env DEBIAN_FRONTEND=noninteractive apt-get -y purge oozie-client
Reading package lists...
Building dependency tree...
Reading state information...
The following packages will be REMOVED:
0 upgraded, 0 newly installed, 2 to remove and 66 not upgraded.
After this operation, 45.5MB disk space will be freed.
(Reading database ... 31042 files and directories currently installed.)
Removing oozie ...
Removing oozie-client ...
Processing triggers for man-db ...
.: 73: Can't open /usr/lib/oozie/bin/oozie-env.sh
invoke-rc.d: initscript oozie, action "stop" failed.
dpkg: error processing oozie (--purge):
subprocess installed pre-removal script returned error exit status 2
dpkg: oozie-client: dependency problems, but removing anyway as you requested:
oozie depends on oozie-client (= 2.3.1-1).
Errors were encountered while processing:
E: Sub-process /usr/bin/dpkg returned an error code (1)