bash mvn command not found Failed to search for file Cannot update read-only repo

0 votes

Hi Guys,

I have installed maven in my system properly. But still it is showing me the below error.

[root@localhost ~]# mvn --version
bash: mvn: command not found...
Failed to search for file: Cannot update read-only repo

How can I solve this error?

Jun 3, 2020 in DevOps & Agile by akhtar
• 38,260 points
5,020 views

1 answer to this question.

0 votes

Hi@akhtar,

You got this error because you didn't set maven path in .bashrc file. Set maven path in .bashrc file, it will not give any error.

export M2_HOME=/maven/
export PATH=/maven/bin:$PATH 

Hope this will help.

answered Jun 3, 2020 by MD
• 95,460 points

Related Questions In DevOps & Agile

0 votes
1 answer

to check file has the same value or not i.e comparing file with stat module.

Try the following script: Do the second time ...READ MORE

answered May 1, 2018 in DevOps & Agile by shubham
• 7,340 points
4,207 views
0 votes
1 answer

docker installation command not found

Here is a simple command which you ...READ MORE

answered Nov 16, 2018 in DevOps & Agile by anonymous
1,797 views
0 votes
1 answer

Docker for Windows error: “Failed to create symbolic link”

The error is telling you that  /var/www/html/externals/public_html ...READ MORE

answered Nov 26, 2018 in DevOps & Agile by Sophie may
• 10,620 points
4,028 views
+15 votes
2 answers

Git management technique when there are multiple customers and need multiple customization?

Consider this - In 'extended' Git-Flow, (Git-Multi-Flow, ...READ MORE

answered Mar 27, 2018 in DevOps & Agile by DragonLord999
• 8,450 points
4,062 views
+2 votes
1 answer
0 votes
1 answer

Failed to restart grafana.service: Unit not found.

Hi@akhtar, After installing grafana in your system, you ...READ MORE

answered May 27, 2020 in DevOps & Agile by MD
• 95,460 points
5,333 views
0 votes
1 answer
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP