-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #53 from angelabriel/master
fixes for new version 5.0.6 (sle15)
- Loading branch information
Showing
7 changed files
with
118 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
#!/usr/bin/env bash | ||
|
||
# sc_hooks.sh is called by post script of sapconf package installation | ||
# to handle some special cases | ||
# e.g. handle special workaround for bsc#1209408 | ||
|
||
if [ "$1" == "" ]; then | ||
echo "ERROR: missing argument" | ||
exit 1 | ||
else | ||
hook_opt="$1" | ||
fi | ||
SN=/etc/sysconfig/sapconf | ||
|
||
add_ignore() { | ||
sed -i 's/^IGNORE_RELOAD=.*/IGNORE_RELOAD=yes/' $SN | ||
} | ||
|
||
del_ignore() { | ||
ignore="nothing" | ||
entry=$(grep '^IGNORE_RELOAD="*yes"*' $SN) | ||
no_entry=$(grep '^# bsc#1209408' $SN) | ||
if [ -n "$entry" ] && [ -z "$no_entry" ]; then | ||
ignore="add" | ||
sed -i 's/^IGNORE_RELOAD=.*//' $SN | ||
fi | ||
echo $ignore | ||
} | ||
|
||
lc_add() { | ||
sed -i 's%^# /etc/security/limits.conf%# /etc/security/limits.d/sapconf-nofile.conf%' "$SN" | ||
sed -i 's/^# SAP Note 1771258$/# SAP Note 1771258 (rev. 6 from 05.11.2021)/' "$SN" | ||
sed -i 's/^# Set to 65536/# Set to 1048576 (as recommended by revision 6 of the SAP Note)/' "$SN" | ||
} | ||
|
||
case "$hook_opt" in | ||
add) | ||
add_ignore | ||
lc_add | ||
;; | ||
del) | ||
del_ignore | ||
;; | ||
nothing) | ||
lc_add | ||
;; | ||
esac |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters