-
Notifications
You must be signed in to change notification settings - Fork 513
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add an initialization action to change the node manager's log directory path to local SSDs #1020
base: master
Are you sure you want to change the base?
Conversation
datasherlock
commented
Oct 6, 2022
- If there are no local SSDs, the script will not add any property to yarn-site and the default boot disk path will be used
- If there are multiple mounts, it will create a comma separated list of paths for the property based on the MAX_MNT_DISK_FOR_LOGS setting.
- If MAX_MNT_DISK_FOR_LOGS is greater than the actual disks, then the actual disk count will be used. If not, the configuration will be honoured.
- The fluentd configuration file is modified to monitor the new path for pushing to Cloud Logging
/gcbrun |
@jainyogesh - Can you please help me find a reviewer for this PR? |
@ranu010101 , @vinayakumarb, @medb - can one of you please help review it or suggest another reviewr |
- Enclosed variables in {} - Enclosed variables in double quotes where applicable.
# This function validates the MAX_MNT_DISK_FOR_LOGS variable and ensures that the value is capped at the max disks available | ||
function get_max_local_ssd() { | ||
max_disk_no=0 | ||
for line in $(df -h --output=target); do |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To be doubly sure let us also add the check for device names. Nothing stops someone from creating /mnt directory in root mount
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
df returns only the filesystems and the mounts points they are mounted on. Even if someone were to create a directory called 'mnt' in /, df wouldn't return the path unless there's a device/filesystem mounted at that mount point.
/gcbrun |