# How can I change the temp directory the MATLAB installer uses?

조회 수: 370(최근 30일)
I am installing MATLAB but the installer cannot run to completion because my /tmp folder is not large enough. Is there anyway I can bypass using /tmp or switch the directory?

### 채택된 답변

MathWorks Support Team 13 May 2020 4:00
편집: MathWorks Support Team 13 May 2020 18:31
The -tmpdir installer flag can be used to change the directory where temporary files are created and deleted during installation.
Warning: If you set the directory or folder without specifying a subfolder to place the temporary files, the -tmpdir installer flag will delete everything inside the directory or folder.
Windows:
Run Command Prompt
Drag the extracted setup.exe into command prompt to create the path.
At the end of the path type, "-tmpdir \path\to\tempfolder\"
As of R2018b, the downloaded archive files will also be in tmp folder. You will also need to use the -downloadFolder flag as well as the -tmpdir flag.
Linux and Mac:
rm -rf \$TEMP_DIR
fi
fi

로그인 to comment.

### 추가 답변(3개)

Ilya Shipachev 4 May 2020
Your solution worked for me. The problem also that Matlab2020a is delivered as .exe installer, but not the setup.exe file. So I had to cancell the installation again after unzipping and go manually to the folder through command line.
I would mention quite popular case I have: Windows installed to the disk C. Disk size is picked around 50Gb to fit all system needs but still running out of space, even though I'm using different disk to install programs and store my files.
I didn't have 10Gb free space on disk C. So I was quite surprised that Matlab is running out of space on disk C when I've picked disk F as an installation location. Some options to pick temporary folders would be nice I think.

#### 댓글 수: 0

로그인 to comment.

Grey Christoforo 29 Jan 2020
편집: Grey Christoforo 30 Jan 2020
These options are not even documented in the installer_input.txt or install_guide.pdf files that I expect to detail all the installer's configuration options. Why are these important parameters being kept secret?
/tmp is a ram disk on many systems[1] and by default the installer is downloading ~10+ of gigabytes into that (depenging on what toolboxes are being installed). Am I missing something? This design seems like its asking for trouble on a lot of situations. Using /var/tmp by defualt may be a good alternative.
[1]: https://en.wikipedia.org/wiki/Tmpfs

#### 댓글 수: 2

Colin Fraser 30 Jan 2020
Hello,
The installer_input.txt is for silent installation and would assume that you already had offline installation files located in the /archives folder already. Therefore, there would be no need to go into TEMP. Your suggestion about including the temp directory information to the install_guide.pdf is a valid point. I have submitted it to our documentation team.
Regards,
Colin Fraser
MathWorks Installation and Licensing Support
Grey Christoforo 30 Jan 2020
That doesn't match with how I can verify that installer_input.txt operates today.
installer_input.txt seems to contain the _option_ for telling the installer to run in silent mode. Other options in that file do not need silent mode to operate properly. For example, if you put your file instiallation key into the installer_input.txt file and run the installer with it, that key gets auto populated in the installer gui and the gui installer runs as expected otherwise.

로그인 to comment.

Ho Sean 15 Apr 2020
This option (-tmpdir) not works in R2020a installer, is there something wrong? or should I disable tmpfs.mount feature in Linux system?

#### 댓글 수: 1

Colin Fraser 29 Apr 2020
Make sure that you set the -downloadFolder flag the same as -tmpdir.
If you are still experiencing this issue, please create a service request below.
-Colin Fraser

로그인 to comment.

이 질문에 답변하려면 로그인을(를) 수행하십시오.

### 태그

아직 태그를 입력하지 않았습니다.

Translated by