-
Notifications
You must be signed in to change notification settings - Fork 28
Description
Problem
After upgrading to Vertica operator v25.3, log files are created with restrictive 600 permissions instead of 644, preventing sidecar containers from reading log files for external log processing.
Root Cause
The lumberjack library upgrade from v2.0.0 to v2.2.1 in commit 7f7bb7aa changed default file permissions as a security
enhancement.
Lumberjack library change:
diff
- mode := os.FileMode(0644) // v2.0.0 - readable by group/others
- mode := os.FileMode(0600) // v2.2.1 - owner-only access
Reference: natefinch/lumberjack@v2.0.0...v2.2.1
Impact
This breaks deployments using sidecar containers to read Vertica log files and forward them to centralized logging systems (ELK, Splunk, monitoring platforms).
Use Case
Common Kubernetes pattern where sidecar containers with shared volumes read /logs/vertica.log to ship logs to external systems for centralized logging and monitoring.
Current Behavior
# v25.3 creates files with restrictive permissions
-rw------- 1 65532 65532 vertica.log # Only owner can read Expected Behavior
# v24.x behavior - allows sidecar access
-rw-r--r-- 1 65532 65532 vertica.log # Group/others can readWorkaround Applied
Modified operator container deployment to use same UID as sidecar container:
securityContext:
runAsUser: 123456 # Match sidecar UID
runAsGroup: 123456 # Match sidecar GID Request
Please consider providing a configuration option to control log file permissions or restore the previous 644 permissions to maintain compatibility with sidecar-based log shipping patterns