# init.m in Autoload directory is not read by parallel kernels in M11.2

Parallel kernels are not reading the init.m files in $UserBaseDirectory/Autoload since version 11.2. The master kernel reads it fine. In earlier versions of Mathematica parallel kernels read these init.m files. Any suggestions? • I don't have v9.0 here, but in 10.0 and later init.m is definitely not evaluated on parallel kernels. – Szabolcs Jan 17 '18 at 16:39 • I believe it worked from FileNameJoin[{$InstallationDirectory, "AddOns", "Autoload", "Kernel", "init.m"}] in 11.0 and 11.1. The key could be the Autoload part. I realise this is a non-standard (or very old) location but it worked, up until 11.2. – Chris Degnen Jan 17 '18 at 16:57
• I think that's an incorrect use of the Autoload directory. It should contain packages, not Kernel/init.m. A package itself may (and should) contain a Kernel/init.m. This init.m has nothing to do with $UserBaseDirectory/Kernel/init.m—it's not an alternative for it. When you put Kernel/init.m in Autoload it considered that a package. – Szabolcs Jan 17 '18 at 17:55 • All that said, it does appear that subkernels stopped loading autoload packages in 11.2, so the solution I suggested no longer works. I think I'll ask support about this because I don't know any other reasonable way to run initialization code on subkernels. – Szabolcs Jan 17 '18 at 17:56 • The sysinit.m file used to have a check for the -noinit option, which would control if Kernel/init.m should load. It also contained the code to load Autoload stuff (unconditionally). None of this is present in sysinit.m anymore in 11.2. These files must be loading by another mechanism. – Szabolcs Jan 17 '18 at 18:05 ## 1 Answer This works ParallelDeveloper$InitCode=Hold[Get[FileNameJoin[{\$BaseDirectory,"Kernel","init.m"}]]]


However, it is undocumented.