-
Bug
-
Resolution: Fixed
-
P2
-
1.4.0
-
02
-
generic
-
solaris_8
-
Not verified
Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-2049425 | 1.4.1 | Rajani Kaja | P2 | Closed | Fixed | hopper |
Here is a suggested prefs install script which should be included into the install script. Please feel free to modify /improve it.
This script creates java.util.prefs system root directory and necessary
files - lock file and mod file.
echo "Is Java going to be used from a network mounted drive? [yes or no]"
read answer
if [ "$answer" = "yes" ]
then
PREFS_LOCATION=$JAVA_HOME
else
PREFS_LOCATION=/etc/.java
fi
echo $PREFS_LOCATION
if [ ! -d $PREFS_LOCATION ]
then
mkdir -m 755 $PREFS_LOCATION
fi
if [ ! -d $PREFS_LOCATION/.systemPrefs ]
then
mkdir -m 755 $PREFS_LOCATION/.systemPrefs
fi
touch $PREFS_LOCATION/.systemPrefs/.system.lock
touch $PREFS_LOCATION/.systemPrefs/.systemRootModFile
chmod 666 $PREFS_LOCATION/.systemPrefs/.systemRootModFile
chmod 666 $PREFS_LOCATION/.systemPrefs/.system.lock
The fix is to create the above mentioned files in /etc/.java with
1. pkgadd
2. if it's a root user installing with *.sh bundle with -localinstall option.
Otherwise they are always created in $JAVA_HOME, the directory where
JRE/JDK is extracted.
This script creates java.util.prefs system root directory and necessary
files - lock file and mod file.
echo "Is Java going to be used from a network mounted drive? [yes or no]"
read answer
if [ "$answer" = "yes" ]
then
PREFS_LOCATION=$JAVA_HOME
else
PREFS_LOCATION=/etc/.java
fi
echo $PREFS_LOCATION
if [ ! -d $PREFS_LOCATION ]
then
mkdir -m 755 $PREFS_LOCATION
fi
if [ ! -d $PREFS_LOCATION/.systemPrefs ]
then
mkdir -m 755 $PREFS_LOCATION/.systemPrefs
fi
touch $PREFS_LOCATION/.systemPrefs/.system.lock
touch $PREFS_LOCATION/.systemPrefs/.systemRootModFile
chmod 666 $PREFS_LOCATION/.systemPrefs/.systemRootModFile
chmod 666 $PREFS_LOCATION/.systemPrefs/.system.lock
The fix is to create the above mentioned files in /etc/.java with
1. pkgadd
2. if it's a root user installing with *.sh bundle with -localinstall option.
Otherwise they are always created in $JAVA_HOME, the directory where
JRE/JDK is extracted.
- backported by
-
JDK-2049425 java.util.prefs system prefs directory setup should be added to install script
-
- Closed
-
- relates to
-
JDK-4669531 system.lock and systemRootModFile have improper permissions.
-
- Closed
-