SSAS Development How to fix "Cannot open BIM Model. Localhost server unreachable" ?

D2d3d4d5 20 Reputation points
2025-02-04T10:14:50.5333333+00:00

Hello everyone !

I've had a weird problem during the last couple of days.

I downloaded a SSAS project from Azure to work on it with some people. I set it up to use "Integrated workspace", and I left everything else as default. The first time I opened it, it was fine, but when I changed the format of a measure and reopened the project, It gave me an error.

It says that the database "localhost" cannot be reached, and I need to verify if an instance is running in VertiPaq mode.

I created the SSAS project with "Integrated workspace", so I assumed the localhost instance would be working correcty.

The temporary fix is to delete the temporary files. More specificaly the "bin/Data/db.X.db" folder and the "bin/Data/db.X.db.xml" file.

Once this is done, I can reopen the project, but if I change any measure, the problem comes back.

Maybe Visual studio tries to load them into the local database, but it fails ?

How can I check that this database is running ?

I use Visual Studio 2019 16.11.40 with the "Microsoft Analysis Projects Services" addon version 2.9.18, and my OS is Windows 11 build 132.0.2957.140 (However I don't think it matters, as there was the same problem before).

My project is pretty small compared to most SSAS projects.

It uses the Integrated workspace, and everything else is default settings.

Do you know a fix for this ?

It's really wasting a lot of time to delete all the temporary files every time I need to work on the project.

I'll try to create the smallest reproducable example to give an idea of what is happening.

PS :

I also found that my problem is very similar to this one :

https://learn.microsoft.com/en-us/answers/questions/1462540/problems-opening-a-tabular-model-file-in-different

However, modifying the Model.bim_XXX.settings doesn't really help.
Visual studio automatically creates one for every user that opens the project, and everyone else that opens the project has the same problem.

Azure Analysis Services
Azure Analysis Services
An Azure service that provides an enterprise-grade analytics engine.
472 questions
SQL Server Analysis Services
SQL Server Analysis Services
A Microsoft online analytical data engine used in decision support and business analytics, providing the analytical data for business reports and client applications such as Power BI, Excel, Reporting Services reports, and other data visualization tools.
1,310 questions
{count} votes

2 answers

Sort by: Most helpful
  1. Smaran Thoomu 19,875 Reputation points Microsoft Vendor
    2025-02-05T14:28:03.8+00:00

    Hi @D2d3d4d5

    Welcome to Microsoft Q&A platform and thanks for posting your query here.
    It looks like your SSAS project is not able to connect to the local integrated workspace in Visual Studio. Since deleting the temporary files helps temporarily, the issue might be with how the workspace database is being managed.

    Here are a few things you can try:

    • Check if SSAS is running in VertiPaq mode - Open Task Manager and look for the msmdsrv.exe process. If it’s not running, the workspace server might not be starting properly.
    • Restart the Integrated Workspace Server - In Visual Studio, go to Tools > Options > Analysis Services Tabular Projects and check if you can restart the workspace database from there.
    • Manually Start the Local SSAS Instance - Open SQL Server Management Studio (SSMS) and try connecting to localhost:51334 (the default SSAS Tabular workspace port). If it doesn’t connect, the workspace may not be starting correctly.
    • Clear and Rebuild the Workspace - Instead of deleting files every time, try clearing the workspace database from Visual Studio > Tabular Model Explorer and then rebuild the model.
    • Check for Conflicts in the Model.bim File - Since this issue happens when making changes, there could be a conflict in the metadata files. You can try creating a new Tabular project and importing the existing model.

    If the problem keeps coming back, you might want to reinstall the Microsoft Analysis Services Projects extension in Visual Studio or try using a different version of Visual Studio 2019.

    Hope this helps! Let me know if you need more details.


    Kindly consider upvoting the comment if the information provided is helpful. This can assist other community members in resolving similar issues.


  2. D2d3d4d5 20 Reputation points
    2025-02-07T16:03:20.37+00:00

    Hello,

    Thank you for your answers.

    I'm very sorry for the late reply.
    It seems that I don't get notification even when folowing a topic.
    Anyways, here is what I tried :

    • Check if SSAS is running in VertiPaq mode - Open Task Manager and look for the msmdsrv.exe process. If it’s not running, the workspace server might not be starting properly.

    It seems that the server runs, however, it seems that doesn't open any ports to connect to it.

    When I do :

    netstat -a -n -p tcp -o | FINDSTR <PID OF PROCESS>

    It doesn't find anything.

    • Restart the Integrated Workspace Server - In Visual Studio, go to Tools > Options > Analysis Services Tabular Projects and check if you can restart the workspace database from there.

    It doesn't seem like I can restart it from here

    • Manually Start the Local SSAS Instance - Open SQL Server Management Studio (SSMS) and try connecting to localhost:51334 (the default SSAS Tabular workspace port). If it doesn’t connect, the workspace may not be starting correctly.

    Sadly it doesn't seem to use the default port... Or any port for that matter

    • Clear and Rebuild the Workspace - Instead of deleting files every time, try clearing the workspace database from Visual Studio > Tabular Model Explorer and then rebuild the model.

    I tried to do that, but sadly it didn't work

    • Check for Conflicts in the Model.bim File - Since this issue happens when making changes, there could be a conflict in the metadata files. You can try creating a new Tabular project and importing the existing model.

    I tried to do that :

    1. I downloaded the Model.bim and the smproject file from my Azure Analysis instance,
    2. I recreated the project from these fileand set it as "localhost"
    3. I change the format of a measure
    4. I restart Visual Studio
    5. I get exactly the same error

    However, these tried did teach us something :

    The server does start running, but no port is ever assigned to it, so Visual Studio can't access it.

    Do you know any tool that can help troubleshooting this ?

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.